The below code will help you get out of the loop.

cout<<"Please type a number then press Enter: \n\n\n";
	integervalue = cin.get();

The code you have writtien doesn't makes any sense to the program. try a different check for the integer value.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.