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
AleksandrR [38]
3 years ago
12

Write a program that takes in a line of text as input, and outputs that line of text in reverse. The program repeats, ending whe

n the user enters "Quit", "quit", or "q" for the line of text.
Computers and Technology
1 answer:
dalvyx [7]3 years ago
7 0

Answer:

string=""

while string not in {"Quit","quit","q"}:

   string=input("Enter line to be reversed")   #line of text will be entered

   if string!="Quit" and string!="quit" and string!="q":    #If quit is not  entered

       print("Reverse of line is : ")

       print(string[::-1])

OUTPUT :

Enter line to be reversedThis code is in python language

Reverse of line is :  

egaugnal nohtyp ni si edoc sihT

Enter line to be reversedHello world

Reverse of line is :  

dlrow olleH

Enter line to be reversedquit

Explanation:In the above program, First a while loop is executed and checked if line of text is not 'quit', 'Quit' or 'q'. If condition is true, then loop is executed and in python any string or list can be traversed from end if step is given -1. Similarly line of text is accessed from the last element. If quit is entered, then the program will be broken out of the loop.

You might be interested in
A new PKI is being built at a company, but the network administrator has concerns about spikes of traffic occurring twice a day
kipiarov [429]

Answer:

Option A (CRL) is the right answer.

Explanation:

  • Certificates with respective expiration date canceled mostly by CA generating or providing them, then it would no longer be tolerated, is considered as CRL.
  • CRL verification could be more profitable for a platform that routinely manages several clients, all having pronouncements from a certain CA, because its CRL could be retrieved once per day.

Other given choices are not connected to the given scenario. So Option A is the right one.

7 0
3 years ago
Which statement best describes multimedia
d1i1m1o1n [39]

Answer:

I couldn't find options to this question online but I will give you an explanation so you can choose the correct answer.

Explanation:

The term multimedia refers to something that uses multiple media simultaneously when transmitting information.

Examples of this can be:

  • photographs
  • sounds
  • text
  • video

Multimedia frames the objects and systems that use multiple physical or digital media to transmit content. It also refers to the media that store and disseminate these types of content.

6 0
4 years ago
What is the output of the following code? public class Test { public static void main(String[] args) { new Person().printPerson(
fredd [130]

Answer:

The output of the given question is :

Person

Person

Explanation:

Following are the description of Statements

  • The new Person().printPerson(); calling the function of printPerson() of the class Person so it returns the Person in the console window.
  • The new Student().printPerson(); calling the function of printPerson() of the class student .The student inherits the class Person So control will moves to the class it executed the statement inside the Person class So it executed the function public void printPerson() of the Person class so it also returns the Person String and execution of program become stops
3 0
3 years ago
HURRY PLEASE
Vika [28.1K]

Answer:

import random

Explanation:

Using the random module in python you could generate a random number.

7 0
3 years ago
Read 2 more answers
How long does Microsoft give a user to activate Windows before displaying a message indicating Windows is not genuine?
Ivan

Answer:

30-day

Explanation:

Microsoft gives you a 30-Day grace period to activate windows

3 0
3 years ago
Other questions:
  • The compare_strings function is supposed to compare just the alphanumeric content of two strings, ignoring upper vs lower case a
    15·1 answer
  • Which of the following are advantages of a local area network, as opposed to a wide area network? select three options
    15·1 answer
  • Why might location be important when searching for a job?
    10·2 answers
  • A résumé can be delivered through _____.a.
    9·2 answers
  • ________ to a base class may be assigned the address of a derived class object.
    8·2 answers
  • Driving is expensive. Write a program with a car's miles/gallon and gas dollars/gallon (both doubles) as input, and output the g
    9·2 answers
  • Which of the following statements is true?
    5·1 answer
  • Will mark brain list
    5·2 answers
  • Facial recognition software can do all of the following, except: Match photos based on facial features Generate a picture based
    10·1 answer
  • Name four successful conversions to an electronic health record system in a medical facility
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!