I am trying to read a backslash as part of a string, but it is always escaped.
For example:
string s = "Bo\nes"
for(int i = 0; i < s.size(); i++) {
if (s[i] == '\\') cout << "Found a backslash";
}
That does not work. And across other testing I always get the string reading as "Boes". How would I be able to read that backslash such that I can parse the entire string?