Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

C++ Help

Name: CandleJack 2008-04-11 1:18

Hey /prog/, I am writing up a program in C++ and for some reason I keep getting an error.
(part of my code)
char x[51];

cin<<x;

if(x=="^Z")
{
//etc etc

And it keeps giving me an error, I have tried single quotes, double, x==('^', 'Z', '\0'), and many more.

Really, all I need is for it to make the program respond to the user pressing Ctrl + Z then hitting enter.

Name: Anonymous 2012-06-05 7:35

>>1
Dipshit. If you use a char array, use strcmp. Elseway use string.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List