How to find "\r" in a conditional?
- by Werner
Hi,
in a C++ program some string reads info from file, and in some part contains a "\r" character. I need to remove it, afte the read, in order to avoid problems. I thought about comparing strings character to character, I thought that "\r" would take two chars, but not, it is just one. how would i use a conditional ? if char[4]==`\r' ???
Thanks
P.D. How would the problem be solved in C?