Why std::cout gave me runtime error?

Revision en1, by Naithani, 2020-06-15 16:15:43

I was solving a problem on LightOj, my solution was correct but the problem was in the std::cout, then I replaced it to printf, then It worked fine. Plz anyone reply, why this happened.

solution with cout link

solution without cout: link

Thanks in advance :)

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English Naithani 2020-06-15 16:59:36 134
en1 English Naithani 2020-06-15 16:15:43 476 Initial revision (published)