Why std::cout gave me runtime error?
Difference between en1 and en2, changed 134 character(s)
I was solving a [problem](http://lightoj.com/volume_showproblem.php?problem=1080) 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](http://lightoj.com/volume_showcode.php?sub_id=1804615)↵

solution without cout: [link](http
s://lightoj.com/volume_showcode.php?sub_id=1804617pastebin.com/ZtdbkWFp)↵

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)