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
eimsori [14]
3 years ago
14

4.24 LAB: Print string in reverse Write a program that takes in a line of text as input, and outputs that line of text in revers

e. The program repeats, ending when the user enters "Quit", "quit", or "q" for the line of text. Ex: If the input is:
Computers and Technology
1 answer:
tresset_1 [31]3 years ago
7 0

Answer:

See explaination

Explanation:

import java.util.Scanner;

public class LabProgram {

public static void main(String[] args) {

Scanner in = new Scanner(System.in);

String line;

while (true) {

line = in.nextLine();

if (line.equals("quit") || line.equals("Quit") || line.equals("q")) break;

for (int i = 0; i < line.length(); i++) {

System.out.print(line.charAt(line.length() - i - 1));

}

System.out.println();

}

}

}

You might be interested in
Ill give alot of points if you answer: How do I get a 100 dollar ps4
stepladder [879]
Uh how do you get a little blue box in a sandwich
8 0
3 years ago
Read 2 more answers
WHAT THE DEFINITION OD ENGINEER. No CHEAT
Harrizon [31]
A person who designs, maintains or builds machines.
4 0
2 years ago
Read 2 more answers
What is the least number of bits you would need to borrow from the network portion of a Class B subnet mask to get at least 130
Tatiana [17]

Answer: Eight

Explanation:

A class B address is 255.255.0.0. We need to borrow 8 bits from the network portion to have atleast 130 host per subnet.

11111111.00000000.00000000.00000000

8 0
3 years ago
The color gradient is
Kipish [7]
A range of position dependent colors
8 0
3 years ago
Which of the following activities are performed by computer programmers? Choose all that apply.
AleksAgata [21]

Answer:

- They write step by step instructions for a computer to follow.

- They create a logic problem that the computer program can solve.

3 0
3 years ago
Other questions:
  • If a secret key is to be used as a _________ for conventional encryption a single number must be generated.
    13·1 answer
  • ___________is a security strategy that applies multiple layers of defense because there is an assumption that any single protect
    12·1 answer
  • Write an expression that will print "in high school" if the value of user_grade is between 9 and 12 (inclusive). Sample output w
    12·1 answer
  • Utility software is also known as _____​
    11·1 answer
  • which telecommunications service allows internet and telephone service to work over the same phone line
    13·1 answer
  • Experienced students may serve as mentors if they are at least age 21 and have at least 3 years of post-secondary education. In
    5·1 answer
  • (d) What other services beside cloud-based software may be provided by Internet hosts?[1]
    11·1 answer
  • Kenny FRIEND ME. Ps that is my brother
    9·2 answers
  • What code would you use to create the login button?
    11·1 answer
  • Describe the concept behind a digital signature and explain how it relates to cybersecurity by providing a hypothetical example
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!