Reputation
6,073
Top tag
Next privilege 10,000 Rep.
Access moderator tools
Badges
6 22 44
Impact
~283k people reached

Aug
17
revised calculate $a/b\ mod\ p$ where p is a prime and a,b can be very large
deleted 48 characters in body
Aug
17
comment calculate $a/b\ mod\ p$ where p is a prime and a,b can be very large
Yes, use the max power of $p$ that divides both numerator and denominator. This max power can be found quickly with binary search.
Aug
15
answered calculate $a/b\ mod\ p$ where p is a prime and a,b can be very large
Jul
14
comment What is the last digit of $\pi$?
@SimonS The best way to answer that question would be a web search. My research area is cryptography, so it's too far afield for me to have anything but recreational interest, but a lot of very interesting math isn't that well-used. It doesn't mean it's not cool or fun to think about. For example, here's a question: we know that $\pi$ is irrational in base 10; is 10 irrational in base $\pi$?
Jul
14
comment What is the last digit of $\pi$?
@SimonS I think I did above: $\pi = 10_\pi$. Irrational bases do lead to weird results, but I'm not the first one to suggest them. I first encountered the idea of irrational (and transcendental) bases in Knuth's 2nd book, but the idea predates even that: mathworld.wolfram.com/Base.html
Jul
6
revised Expected value when die is rolled $N$ times
typography
Jul
2
comment proof by contradiction puzzle
Isn't this just en.wikipedia.org/wiki/Chomp ?
Jun
29
answered How many edges in a graph with $n$ vertices are needed to guarantee it is connected?
Jun
10
comment What is the worst-case running time of this algorithm?
@Henry That's a good suggestion. Or "unbounded" even.
Jun
10
asked What is the worst-case running time of this algorithm?
Feb
19
awarded  Great Question
Feb
18
awarded  Popular Question
Feb
18
awarded  Revival
Feb
16
awarded  Yearling
Feb
5
comment Problem about combinations and permutations
The first customer has 14 choices, the next 13, and the last 12. It's 14P3, not 14C3.
Oct
14
comment $\gcd(p, (p-1)!) = 1$?
Wilson's theorem settles this in 1 step: en.wikipedia.org/wiki/Wilson's_theorem
Sep
30
awarded  Explainer
Sep
24
awarded  Autobiographer
Sep
11
awarded  Good Question
Jul
15
revised Finding rational points at rational distance in the plane
deleted 1 character in body