Skip to content

Commit 4fd0aae

Browse files
authored
A little spell check that's it
I corrected the typo by removing the extra "all" in the first sentence of [https://cp-algorithms.com/algebra/phi-function.html#etf_1_to_n]. It seems like a small mistake. Thanks for the tutorial, though!
1 parent d7bcea6 commit 4fd0aae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/algebra/phi-function.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ int phi(int n) {
7373
7474
## Euler totient function from $1$ to $n$ in $O(n \log\log{n})$ { #etf_1_to_n data-toc-label="Euler totient function from 1 to n in <script type=\"math/tex\">O(n log log n)</script>" }
7575
76-
If we need all all the totient of all numbers between $1$ and $n$, then factorizing all $n$ numbers is not efficient.
76+
If we need the totient of all numbers between $1$ and $n$, then factorizing all $n$ numbers is not efficient.
7777
We can use the same idea as the [Sieve of Eratosthenes](sieve-of-eratosthenes.md).
7878
It is still based on the property shown above, but instead of updating the temporary result for each prime factor for each number, we find all prime numbers and for each one update the temporary results of all numbers that are divisible by that prime number.
7979

0 commit comments

Comments
 (0)