1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Svetllana [295]
3 years ago
6

Write a program that prints the question " Do youwant to continue? " and reads a user input. if the userinput is " Y ", " OK", o

r " Why not? ", printout " OK ". if the user input is "No " , then print out " Terminating ", Otherwise print " Bad input". The case of the user input should notmatter. For example, "y" or "yes" are also valid inputs. Write aclass YesNoChecker for this purpose.
Computers and Technology
1 answer:
Nataly_w [17]3 years ago
7 0

Answer:

#include <bits/stdc++.h>

using namespace std;

int main() {

   string in;//string in for taking input...

   cout<<"Do you want to continue ?"<<endl;

   getline(cin,in);//taking input from the user...

   if(in=="y"||in=="Y"||in=="yes"||in=="OK"||in=="Why not?")//conditions..

   cout<<"OK"<<endl;

   else if(in=="No")

   cout<<"terminating"<<endl;

   else

   cout<<"Bad input"<<endl;

return 0;

}

Explanation:

I have taken a string in.

Then taking input from user.

Checking the conditions using if else if ladder.

You might be interested in
JavaScript is the same thing as Java?
Mila [183]

Not really, because Java is an OOP programming language and JavaScript is an OOP scripting language.

Hope I helped!

~Mshcmindy

5 0
3 years ago
Read 2 more answers
Amye is in high school. As part of one of her classes, she had to identify the legality of different situations that involved
adell [148]
I say you should pick answer 1. an HR makes more sense since she is interested in a topic about the legality of different situations that are related to workers and their employers.
8 0
3 years ago
Read 2 more answers
In computer science, what are two names that are used to describe data structures organized by association
Bas_tet [7]

Answer:

Answer to the following question are,

  • Association list
  • Tables

Explanation:

Because these are the two associations data structures.

  • Association List: are referred to that data type which contains the pair of the key and item in the Java Programming Language and Python Programming Language, it is called a dictionary data type.
  • Tables or Hash Tables: are referred to that data type which converts the keys into the integer value.
6 0
3 years ago
3. How do robots help speed up the fulfillment of orders at some Amazon warehouses?
vagabundo [1.1K]

Answer:

B is the only answer that makes sence

6 0
3 years ago
Read 2 more answers
Microsoft word 365 allows cells to be split into how many columns
Bogdan [553]

Answer:

Microsoft word 365 allows two columns

8 0
3 years ago
Read 2 more answers
Other questions:
  • Your computer has two basic types of software: system software and ________ software.
    9·1 answer
  • Can someone please help me? I have no clue what any of this is and how I'm going to find out 15 examples of these. It's due some
    5·1 answer
  • You are the system administrator for a medium-sized Active Directory domain. Currently, the environment supports many different
    7·1 answer
  • FIND THE 6 ERRORS IN THIS RESUME 30 POINTS!!!!
    12·1 answer
  • What HTML tag would you use to indicate a line break?
    5·1 answer
  • In addition to ranking the relevance of a particular site according to the keywords entered by the user, which of the following
    10·1 answer
  • On an XBOX 360, what does it mean if you get 4 red rings on your console?
    5·1 answer
  • What are some common uses of Excel?
    10·1 answer
  • Suppose we used an internet addressing protocol that used 4 bits to encode a single address. How many devices would be supported
    15·1 answer
  • Many people are scared of the rise of Artificial Intelligence (AI). Do you think computers that are controlled by an AI are some
    11·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!