tidying up
A very difficult probability problem. It takes me quite some time to write the code for a brute force method(well, it is not Monte Carlo). I found it was too slow, and also took too much memory. Then based on this brute force version, I did some optimization to reduce the memory cost since something are actually equivalent. However, after the optimization, It still took 16 seconds.
Please read the discussion thread, there is a very smart way to solve this problem.
No comments:
Post a Comment