#include <iostream>
usingnamespace std;
char moveto;
void playgamez()
{
cout<<"You are now standing on z. Were do you want to move?\n";
cout<<"[q][w][e]\n[a][s][d]\n[0][x][c]\n";
cin>> moveto;
cin.get();
}
int main()
{
char moveto;
int array[3][3];
cout<<"You are standing on 4. Were do you want to move?\n";
cout<<"[q][w][e]\n[a][0][d]\n[z][x][c]\n";
cin>> moveto;
cin.get();
switch ( moveto ) {
case z:
playgamez();
break;
case x:
x();
break;
case c:
c();
break;
case a:
a();
break;
case s:
s();
break;
case d:
d();
break;
case q:
q();
break;
case w:
w();
break;
case e:
e();
break;
}
}
When i try to compile this i get this error: error: 'z' was not declared in this scope. I get this error on line 32,35,38,41,44,47,50,53,56. Can anyone tell me what I have to change to get it to work?