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
olga_2 [115]
3 years ago
11

Write a program that accepts inputs, outputs them and exits correctly when - 1 is pressed

Computers and Technology
1 answer:
dolphi86 [110]3 years ago
7 0

Answer:

Explanation:

The following program is written in Python. It simply creates an endless loop that continously asks the user for an input. If the input is not -1 then it outputs the same input, otherwise it exists the program correctly. A test output can be seen in the attached image below.

while True:

   answer = input("Enter a value: ")  

   if answer != "-1":

       print(answer)

   else:

       break

You might be interested in
TCP will guarantee that your packets will arrive at the destination, as long as the connection is still established. True False
puteri [66]

Answer: True

Explanation: TCP(Transmission control protocol) is the protocol that is responsible for making the connection between the two hosts and then  they can share the data between them.

TCP guarantees that the data or data packets that are being sent from the source will be delivered to the host  in the same way as it was sent from source port. This mechanism ensure that there will be no data manipulation in the order of the data. TCP also has a relation with the IP for the functioning.Thus the given statement is true.

3 0
3 years ago
In what country have regulators demanded that facebook stop collecting biometric data on its users?
Helga [31]
America or Australia
6 0
4 years ago
100 POINTS!!!!
Alisiya [41]

Answer:

☆<em>intellectual property</em>☆

<u>intangible </u><u>a</u><u>s</u><u>s</u><u>e</u><u>t</u><u>s</u><u> </u><u> that result from intellectual</u><u> </u><u>p</u><u>r</u><u>o</u><u>p</u><u>e</u><u>r</u><u>t</u><u>y</u><u> </u><u>.</u>

<u>☆</u><u>I</u><u>n</u><u>t</u><u>a</u><u>n</u><u>g</u><u>i</u><u>b</u><u>l</u><u>e</u><u>☆</u><u>;</u>

<u>s</u><u>o</u><u>m</u><u>e</u><u>t</u><u>h</u><u>i</u><u>n</u><u>g</u><u> </u><u>t</u><u>h</u><u>a</u><u>t</u><u> </u><u>c</u><u>a</u><u>n</u><u>n</u><u>o</u><u>t</u><u> </u><u>b</u><u>e</u><u> </u><u>t</u><u>o</u><u>u</u><u>c</u><u>h</u><u>e</u><u>d</u><u>.</u>

<em>P</em><em>l</em><em>e</em><em>a</em><em>s</em><em>e</em><em> </em><em>M</em><em>a</em><em>r</em><em>k</em><em>☆</em>

<em>A</em><em>r</em><em>i</em><em>a</em><em>♡</em>

5 0
3 years ago
Microsoft has developed the Active Directory Domain structure so that a central authority, called the __________, is the reposit
Zielflug [23.3K]

Answer: Domain controller

Explanation: Active Directory is the technology developed by Microsoft which provides help in centralized handling and managing of the devices on any network.  It has the ability of operating internet servers as well as local servers.

Domain controller is the main server unit for where the database of Active directory is deposited.It keeps the records related with standards, authentication , authorization etc , which are defined as the domain security data record.

8 0
4 years ago
Python - Please help!
Margaret [11]

Answer:

i= 1

for i in range(1,n):

     if i * i < n:

           print(2* i + 1)

     i += 1

else:

     print('Hakuna Matata')

Explanation:

First, there's a need to rewrite the code segment in your question (because of indentation)

<em>i= 1</em>

<em>while i*i < n:</em>

<em>      print(2* i + 1)</em>

<em>      i += 1</em>

<em>else:</em>

<em>      print('Hakuna Matata')</em>

<em />

The explanation of the equivalent of the above while loop is as follows

This line initializes i to 1

i= 1

This line iterates from 1 to n-1

for i in range(1,n):

This line checks if i * i is less than n

     if i * i < n:

The following line is executed if the above condition is satisfied; otherwise, nothing is done

           print(2* i + 1)

The value of i is incremented by 1 using this line

     i += 1

The following is executed at the end of the iteration

else:

     print('Hakuna Matata')

<em>Note: Assume any value of n, both programs display the same output</em>

6 0
3 years ago
Other questions:
  • Under the common criteria, which term describes the user-generated specifications for security requirements?
    12·1 answer
  • What are personal skills? A manner of individual style How a person manages and expresses oneself One's ability to excel at spor
    13·2 answers
  • Summarize the distinction between a flat file and a database
    15·1 answer
  • Enables you to navigate through pieces of information by using links which connect them.
    10·1 answer
  • A user is troubleshooting a mobile device app that is displaying errors and has contacted the app manufacturer’s technical suppo
    14·1 answer
  • When using a public computer or network, you should always _______. A. install a firewall. B. run an anti-virus program beforeha
    11·2 answers
  • Three different numbers need to be placed in order from least to greatest. For example, if the numbers are ordered 9, 16, 4, the
    9·1 answer
  • CLS
    12·1 answer
  • Please please help I don’t understand this please.
    11·1 answer
  • Question 1
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!