ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1310. ACM Diagnostics

Alexandru Popa How big is N for test 16 ? [3] // Problem 1310. ACM Diagnostics 1 Jul 2005 01:18
Michael_Rybak N can be 50^100 (-) [2] // Problem 1310. ACM Diagnostics 15 Feb 2006 20:03
-
SPIRiT No, it can't be!(+) [1] // Problem 1310. ACM Diagnostics 28 Aug 2006 12:47
N is much smaller than 50^100. 50^100 - is the number of all possible states, but N is the order of all ALLOWABLE states (whose sum mod K = 0 )and that's quite less, but still does not fit even in int64 :(. Wherefore, you have to use long arifmetics.
Denis Koshman Re: No, it can't be!(+) // Problem 1310. ACM Diagnostics 13 Aug 2008 02:51
If K=1, you'll get your 50^100 :)