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
Sergio [31]
3 years ago
5

Write a program that asks the user for three names, then prints the names in reverse order.

Computers and Technology
1 answer:
sasho [114]3 years ago
8 0

Answer:

The program written in C++ is as follows'

#include<iostream>

using namespace std;

int main()

{

string names[3];

cout<<"Please enter three names: "<<endl;

for (int i = 0; i< 3;i++)

{

cin>>names[i];

}

for (int i = 2; i>= 0;i--)

{

cout<<names[i]<<endl;

}

return 0;

}

Explanation:

This line declares an array for 3 elements

string names[3];

This line prompts user for three names

cout<<"Please enter three names: "<<endl;

This following iteration lets user input the three names

for (int i = 0; i< 3;i++)  {  cin>>names[i];  }

The following iteration prints the three names in reverse order

for (int i = 2; i>= 0;i--)  {  cout<<names[i]<<endl;  }

You might be interested in
The chief reason that family and friends are frequent targets of aggression is that
iris [78.8K]
The correct answer is letter D. they're convenient. The chief reason that family and friends are frequent targets of aggression is that (D) they're convenient. Aggression is he feeling of harmful in terms of social interaction with the intention or goal of damaging other individual. Family and friends have already made a big interaction between each other.
5 0
3 years ago
a paragraph is a segment of text with the same format that begins when you press the enter key and ends when you press enter key
Usimov [2.4K]
You yourself put the answer to the question in the Question. the answer is paragraph. lol
7 0
3 years ago
Read 2 more answers
According to the Bureau of Labor Statistics, how
Vladimir79 [104]

Answer:

one million

Explanation:

took test

7 0
3 years ago
Type the correct answer in the box. Spell all words correctly.
faltersainse [42]

The resource allocation section of the test plan contains the information regarding the features to be tested in the test plan.

<h3>What is resource allocation?</h3>

The distribution and disbursement of the total disposable resources within an organization towards the different functions and processes in an organization is referred to as resource allocation.

The main functionality of a resource allocation section in a test plan is to portray the features of the test that will be conducted by the team of experts.

Hence, the functions of resource allocation in a test plan are as aforementioned.

Learn more about resource allocation here:

brainly.com/question/17837067

#SPJ1

5 0
2 years ago
Write a program Using loops to display the following patterns –
lukranit [14]

Answer:mm, no se como

Explanation:ayudarte

5 0
3 years ago
Other questions:
  • Test if a password entered is correct. The secret phrase is Ada Lovelace. Sample Run 1 Enter the Password: Ada Lovelace Sample O
    13·1 answer
  • Write a program that inputs a line of text and uses a stack object to print the line reversed.
    14·1 answer
  • Using the expected format, of putting key information where the reader can’t find it, is an example of?
    8·2 answers
  • Unix/linux are ____ systems, which let many people simultaneously access and share the resources of a server computer.
    13·1 answer
  • Each time the user selects an item from a list box in a web page, a postback occurs, the web page will redisplay, and the page_l
    12·1 answer
  • Individuals who require better speed and performance for graphics-intensive applications (e.g., video editing, gaming, etc.) pre
    8·1 answer
  • Nikolas has a idea that he could use the compressed carbon dioxide in a fire extinguisher to propel him on his skateboard. Nikol
    13·2 answers
  • Thomas drew a rectangle with an area of 6 square cm what is the greatest possible perimeter of this rectangle
    5·1 answer
  • Choose and explain, step by step, one method of backing up student files either manually or using a cloud service.
    10·1 answer
  • What is being done to reduce the python population in florida?.
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!