Question: C++ - I'm having a problem with the while loop, I get two compile errors from that specfic line(line 46). invalid conversion from 'const char*'

 C++ - I'm having a problem with the while loop, I

C++ - I'm having a problem with the while loop, I get two compile errors from that specfic line(line 46).

"invalid conversion from 'const char*' to 'char'" "suggest parentheses around assignment used as truth value"

I'm extremely confused on where to go from here.

#include 3 #include 5 using namespace std; 7 int main ) 9 char selection 10 int cents; 12 do 13 14 cout selection; switch (toupper (selection)) 16 17 18 case 'P 20 21 cents = 125; cout

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!