Anormous data input

Why is it so that… for same program… exactly same… C program is running fast then C++…

There is no major difference, just in C++ i’m using cin, cout and in C i’m using scanf,printf…
plzz someone please reply.

Read FAQ please - FAQ | CodeChef

The second most common cause of TLE is that your method of reading input and writing output is too slow. In Java, do not use a Scanner; use a BufferedReader instead. In C++, do not use cin/cout - use scanf and printf instead.

3 Likes