problem with cout, cin n scanf, printf

few minutes before, i made a submission,
on first attempt,when i made it using (cin and cout) it showed me Time Limit Exceeded(TLE)…
but then i read FAQ’s it was written there, use scanf n printf, instead of cin and cout…
so, i just replaced, (cin by scanf) and (cout by printf), and it was accepted…
explanation wasn’t given there…
SO IF ANYONE KNOWS THE EXPLANATION…PLEASE COMMENT BELOW…

thnks in advance…:slight_smile:

It’s written in FAQ - “your method of reading input and writing output is too slow”.

cin and cout is slower than scanf and printf

2 Likes
//