Computers and Technology
Computers and Technology, 02.11.2019 06:31, ewinter13

Consider the following code:
a) num = int(input("enter a number, negative to stop"))
b) while (num > = 0):
print ("you entered: " + str(num))
c) num = int(input("enter a number, negative to stop"))
print ("done.")
what is wrong?
d) the num > = 0 test condition is not correct
there is nothing wrong with the code.
the line num = int(input("enter a number, negative to stop")) should be indented so it is inside the loop
e) there should not be a : after the while (num > = 0)

answer
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 16:50, jaueuxsn
3(c). is the following command correct? if not, correct the syntax and explain your answers. you can just rewrite/correct only the wrong parts. (4) select p#, city, zipcode, count(*) from client c, property p, viewing v where c. c# = v. c# and v. p# = p. p# group by p#, city having count(*) > 3;
Answers: 1
image
Computers and Technology, 21.06.2019 17:30, staz13wiggins
How many pairs of chromosomes do human body cells contain?
Answers: 2
image
Computers and Technology, 22.06.2019 16:20, mandy9386
Consider the following statements, then select one of the answers below: the signal() function shown below registers "sig_handler()" as the signal handler function for the sigkill signal, without the complexity of using when the sigkill signal is sent to a process running this code, by a user typing "kill -kill ", where the correct process id is used for to target the process, sig_handler() will be executed.
Answers: 1
image
Computers and Technology, 22.06.2019 23:30, ansonhunter8891
What are listed in the vertical columns across the top of the event editor? a. file names b. conditions c. check marks d. action types
Answers: 1
Do you know the correct answer?
Consider the following code:
a) num = int(input("enter a number, negative to stop"))
b)...

Questions in other subjects:

Konu
English, 24.03.2021 17:10
Konu
Mathematics, 24.03.2021 17:10