I have been coding in C++ for a long time. I always wondered which has a faster execution speed printf or cout?
printf
cout
Situation: I am designing a
If you're using C++, you should use cout instead as printf belongs to the C family of functions. There are many improvements made for cout that you may benefit from. As for speed, it isn't an issue as console I/O is going to be slow anyway.