This is part of a bigger program, but essentially, what's happening is that "stringB" isn't being allowed to be written properly. After I type in 10 characters it tells me that the length isn't right. If I hit enter 9 times, the prompt to retry comes up, and it will accept the 10 characters. This is after a lot of cout/cin back and forth. I started using cin.sync() and it seemed to alleviate some issues, but I'm not really sure if buffers are the root cause, or if I'm just maybe losing my mind. Code follows:
Very interesting! Thank you for your informative response! If cin.read() is for binary, how would that be implemented? Unless cin is actually reading the binary value of the keys typed. I hadn't thought of incrementing the 'tries' in the while condition and I need to read a bit more on strings. Thank You Again!