Comments

I was playing with some code and I tried to comment out some cin >> and it doesn't comment it out. Wondering if there is an easier way to ignore the code. Tried single line // comment too. Using Visual Studio Express 2012.

1
2
3
4
 /*cout << "Enter First Name: "; cin >> first_name;
 cout << "Enter Last Name: "; cin >> last_name;
 cout << "Enter Age: "; cin >> age;	
 cout << endl << "Enter the name of the file: "; cin >> file_name;*/
It looks commented to me. Are you sure you re-compiled/re-built everything before running it? Try giving us a full program that doesn't work.
Yeah, it looks right here but in Visual Studio express 2012, only the " " changes green. Everything else is still the normal, non-commented colors. And it'll run the cin's still. It's probably something with Visual Studio.
Topic archived. No new replies allowed.