mirror of
https://github.com/TheAlgorithms/JavaScript.git
synced 2025-07-05 00:01:37 +08:00
some changes in coding style to make it standerize
This commit is contained in:
@ -19,7 +19,7 @@ const gcdOfTwoNumbers = (x, y) => {
|
|||||||
|
|
||||||
const eulersTotientFunction = (n) => {
|
const eulersTotientFunction = (n) => {
|
||||||
let countOfRelativelyPrimeNumbers = 1
|
let countOfRelativelyPrimeNumbers = 1
|
||||||
for (let iterator = 2; iterator <= n; iterator++){
|
for ( let iterator = 2; iterator <= n; iterator++ ){
|
||||||
if (gcdOfTwoNumbers(iterator, n) === 1)countOfRelativelyPrimeNumbers++
|
if (gcdOfTwoNumbers(iterator, n) === 1)countOfRelativelyPrimeNumbers++
|
||||||
}
|
}
|
||||||
return countOfRelativelyPrimeNumbers
|
return countOfRelativelyPrimeNumbers
|
||||||
|
Reference in New Issue
Block a user