We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
for N=4, is the following results correct? if my understanding of the problem statement is correct, I think the results should be correct, but it cannot pass the test case
0 0 0 0: 0
0 0 0 1: 1
0 0 0 2: 1
0 0 1 0: 2
0 0 0 3: 1
0 0 1 1: 500000005
0 0 0 4: 1
0 0 1 2: 333333337
0 0 2 0: 500000005
0 1 0 0: 500000006
0 0 1 3: 250000003
0 0 2 1: 388888893
0 1 0 1: 916666675
0 0 2 2: 319444448
0 1 0 2: 694444451
0 1 1 0: 652777784
0 1 1 1: 555555561
1 0 0 0: 555555562
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #151: Paper sheets of standard sizes: an expected-value problem.
You are viewing a single comment's thread. Return to all comments →
for N=4, is the following results correct? if my understanding of the problem statement is correct, I think the results should be correct, but it cannot pass the test case
0 0 0 0: 0
0 0 0 1: 1
0 0 0 2: 1
0 0 1 0: 2
0 0 0 3: 1
0 0 1 1: 500000005
0 0 0 4: 1
0 0 1 2: 333333337
0 0 2 0: 500000005
0 1 0 0: 500000006
0 0 1 3: 250000003
0 0 2 1: 388888893
0 1 0 1: 916666675
0 0 2 2: 319444448
0 1 0 2: 694444451
0 1 1 0: 652777784
0 1 1 1: 555555561
1 0 0 0: 555555562