Whats the most efficient way of removing a \'newline\' from a std::string?
Use std::algorithms. This question has some suitably reusable suggestions Remove spaces from std::string in C++