hey this is a just for fun topic (a.k.a. NOT homework) but if you can please reply:
I am working in Visual C++ and I can't get any operation to write a single character to a variable and then check it in an if() statement. Here is my last try:
Your if statements are both using the assignment operator "=" instead of the equality operator "==". The first one will always set k to 'r' and then print it.