Question 17
Back to Exercise
What does std::ios::sync_with_stdio(false); do?
- A Turns off all output
- B Stops synchronising C++ streams with C stdio, which makes cin/cout much faster – but they must not be mixed with printf/scanf afterwards Correct
- C Makes cin read from a file
- D Enables multithreaded I/O
Correct Answer: Option B
It is usually combined with std::cin.tie(nullptr), which stops cin from flushing cout before every read.
Discussion & Comments 0
Share your method, a shortcut, or ask about a step you didn't follow.
No comments yet. Be the first to share your solution!