Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ How to write a while loop that checks for everything other than integers. Idea that I'm going for is cout < < please enter

C++

How to write a while loop that checks for everything other than integers.

Idea that I'm going for is

cout << "please enter integer 1";

cin >> int1

cout << "please enter integer 2";

cin >> in2

while ( in1 && int2 != int ) {

cout << "invalid input please enter an integer";

}

But not sure how to implement proper while parameters.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts

Authors: David Kroenke

4th Edition

0136086535, 9780136086536

Students also viewed these Databases questions

Question

What is organizational flattening? Why is it practiced?

Answered: 1 week ago