tiktak2's blog

By tiktak2, history, 4 years ago, In English

I've tested one of my submission 95709609 which works fine with the test cases where modulo operation is not mandatory/ not becomes overflow. But in case large string , overflow occurs. May be I don't know modulo operation well. I'm trying to learn it. But if u make my code fixed by making the modulo operation then I will be glad & learn from u too. Before downvoting , please leave at least a comment.

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
4 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Try taking mod for every addition and multiplication, on both operands and then on the answer, also add mod value when subtracting(then mod again) to ensure only positive values.