You can hot have declare a variable in there. You are trying to declare c in there with char.Code:while(char c = cin.get() != 'q')
You have to declare the variable outside.Code:char c; while((c = cin.get()) != 'q')
You can hot have declare a variable in there. You are trying to declare c in there with char.Code:while(char c = cin.get() != 'q')
You have to declare the variable outside.Code:char c; while((c = cin.get()) != 'q')