5,677 reputation
52142
bio website
location California
age
visits member for 3 years, 9 months
seen 15 hours ago

A mediocre professor at a top-notch university making mediocre contributions to this top-notch community


May
1
suggested suggested edit on Graph - finding cycles which contain specific edegs in O(|V| + |E|) (by DFS?)
May
1
comment Decryption Problem
@Brandon: Hah! Ok, you got me. Cryptographers create, cryptanalysts break, and cryptologists do both. The main conference in our field is called Advances in Cryptology, but I rarely use that term it forums like this one because it's not known to lay audiences. But yeah, cryptanalysts was the proper word.
Apr
30
revised Decryption Problem
added 2 characters in body
Apr
30
answered probability of at least one person having a gem of type $n$, etc.
Apr
28
answered Simple or maybe not so simple probabilistic question
Apr
28
comment Calculating the highest possible damage achievable using 6 items from a pool of ~25
@Shawn: Yuval used the standard method to count combinations with repetitions. See en.wikipedia.org/wiki/…
Apr
26
revised Calculating the highest possible damage achievable using 6 items from a pool of ~25
added 130 characters in body
Apr
26
comment Calculating the highest possible damage achievable using 6 items from a pool of ~25
@Shawn: Just test the cost in the inner loop and include the item-set only if the cost is under the budget. By the way, the folks around here are very helpful and friendly, but to be honest I think your question would find a better home on stackoverflow or programmers.SE. Cheers!
Apr
26
revised Calculating the highest possible damage achievable using 6 items from a pool of ~25
Allow duplicate combos in the code example
Apr
26
comment Calculating the highest possible damage achievable using 6 items from a pool of ~25
@Shawn: if you want to allow a,a,a,a,a,a then start each for loop at the value before it (rather than the value + 1). I edited my code above to do this. It increases the number of total loops to 593,775 from 177,100.
Apr
26
comment Calculating the highest possible damage achievable using 6 items from a pool of ~25
I was assuming that you have a set of helm, shoulder, bracer, glove, chest, and leg items and that you couldn't equip a given item other than in its proper slot. If you want to avoid repetitions, use the code above which will give you the 177,100 unique sets of 6 items taken from 25.
Apr
26
revised Calculating the highest possible damage achievable using 6 items from a pool of ~25
add some code
Apr
26
answered Calculating the highest possible damage achievable using 6 items from a pool of ~25
Apr
26
comment Computing the integral of $e^{-x^2}$ over the entire line
@Arturo & Ross: both links give the same proof... which is indeed quite slick. Cheers. (I would delete my question now, but it already has an answer, so this is disallowed.)
Apr
26
asked Computing the integral of $e^{-x^2}$ over the entire line
Apr
24
comment Run of $N$ successes before run of $k$ failures
Google found a math.SE question that was 45mins old when you searched? Wow.
Apr
21
comment How to rotate n individuals at a dinner party so that every guest meets every other guests
You might want to check out en.wikipedia.org/wiki/Combinatorial_design
Apr
21
awarded  Quorum
Apr
20
comment Calculate which day of the week a date falls in using modular arithmetic
I actually teach this algorithm in my algorithms class; it's useful in real life to be able to do this!
Apr
18
comment Motivation for the Math Required for Computer Science
@Taylor: Your question would resonate more with people here (and you would likely get a better answer) if you were more specific. Try changing the Title and some of the text to a more specific question like "what is a real-world application of Bayes' Theorem" for example.