3 ms·
std::cout is thread-safe but because of the concatenation-based API parts of the message may interleave. C++23 std::print is safe (and the output doesn't interl
by vitaut 3y ago
std::cout is thread-safe but because of the concatenation-based API parts of the message may interleave. C++23 std::print is safe (and the output doesn't interleave).
See https://vitaut.net/posts/2023/print-in-cpp23/ https://vitaut.net/posts/2023/print-in-cpp23/.