What is the difference between std::ios_base::sync_with_stdio( false );
Vs std::cout.sync_with_stdio( false );
and std::cin.sync_with_stdio( false );
?
Which one should I use supposing my code does not use any of the C streams from <cstdio>
and only uses C++ streams from <iostream>
?
I want to know:
- what are the advantages of disabling the synchronization?
- What can go wrong if synchronization is set to false? Which things should I take into account if I want to disable the synchronization?