Here is the link to the Problem and Solution of December cook-off YVNUM.
There is one thing in this solution which i cant get my head around -
when the number becomes too big we take the modulo of the number wrt to 1000000007 instead of the original number and then do the concatenation operation with it rather than the original number and then expect the answer to be same, will it work??
Ex. string 921, modulo number = 103
921%103 = 97 but we find that (921219192)%103 != (977997)%103
Please tell me where am i wrong.