archive 3015 - Zeros and Ones

Do you want to discuss about these problems? Go now!
Users are shared (no need to re-register).

Moderator: Board moderators

Post Reply
Sanny
Learning poster
Posts: 78
Joined: Sat Feb 14, 2004 3:59 pm
Location: BUET
Contact:

archive 3015 - Zeros and Ones

Post by Sanny » Wed Jun 08, 2005 5:04 pm

Anybody can check this i/o please. I'm getting WA :(


Input:

Code: Select all

15
1 0
63 100
64 1
64 0
53 53
54 54
50 99
10 100
25 25
64 100
6 3
6 4
6 2
26 3
64 2
Output:

Code: Select all

Case 1: 0
Case 2: 0
Case 3: 916312070471295267
Case 4: 916312070471295267
Case 5: 0
Case 6: 18358397026615
Case 7: 637606458151
Case 8: 0
Case 9: 0
Case 10: 9308567063712721
Case 11: 1
Case 12: 3
Case 13: 6
Case 14: 1662453
Case 15: 465428353255261088
Regards
Sanny

sidky
New poster
Posts: 50
Joined: Wed Nov 06, 2002 1:37 pm
Location: Planet Earth, Universe
Contact:

Post by sidky » Thu Jun 09, 2005 4:55 pm

My AC code gives this output

Code: Select all

Case 1: 0
Case 2: 0
Case 3: 916312070471295267
Case 4: 0
Case 5: 0
Case 6: 18358397026615
Case 7: 637606458151
Case 8: 0
Case 9: 0
Case 10: 9308567063712721
Case 11: 1
Case 12: 3
Case 13: 6
Case 14: 1662453
Case 15: 465428353255261088

Sanny
Learning poster
Posts: 78
Joined: Sat Feb 14, 2004 3:59 pm
Location: BUET
Contact:

Post by Sanny » Thu Jun 09, 2005 5:00 pm

Got AC now. My mistake was when K=0. Thanks.

Post Reply

Return to “ACM ICPC Archive Board”