We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b87c713 commit 7717abcCopy full SHA for 7717abc
math/modular_inverse_fermat_little_theorem.cpp
@@ -30,8 +30,8 @@
30
* a^{m-2} &≡& a^{-1} \;\text{mod}\; m
31
* \f}
32
*
33
- * We will find the exponent using binary exponentiation. Such that the
34
- * algorithm works in \f$O(\log m)\f$ time.
+ * We will find the exponent using binary exponentiation such that the
+ * algorithm works in logarithmic time.
35
36
* Examples: -
37
* * a = 3 and m = 7
@@ -58,7 +58,7 @@ namespace math {
58
*/
59
namespace modular_inverse_fermat {
60
/**
61
- * @brief Calculate exponent with modulo using binary exponentiation.
+ * @brief Calculate exponent with modulo using binary exponentiation in \f$O(\log b)\f$ time.
62
* @param a The base
63
* @param b The exponent
64
* @param m The modulo
0 commit comments