idjfjcjs7291 idjfjcjs7291
  • 02-12-2022
  • Computers and Technology
contestada

Write a program that accept a whole number a input, mutiplie that number by 21, and then output the product

Respuesta :

candlejenner candlejenner
  • 03-12-2022

Answer:

while True:

   try:

       whole_number = int(input("Enter a whole number: "))

       break

   except ValueError:

       print("That is not a whole number. Try again.")

product = whole_number * 21

print("The product is", product)

Explanation:

using while true and except ValueError to make sure the user enters a whole number

Answer Link

Otras preguntas

Please answer correctly for brainly
What style of art was adopted as a means of spreading Christianity during the counter reformation
How was Julius Caeser able to defy the senate, cross the Rinicon, and engage in a civil war with his enemies
Escucha la frase y escoge la respuesta más lógica. Click here for the audio. Me gustaría un bistec encebollado y camarones con ajo y mantequilla, una papa hor
Will Give brainliest! Examine the diagram. Name two corresponding angles to ∠1. ∠6 and ∠15 ∠5 and ∠6 ∠13 and ∠15 ∠5 and ∠13
Which number is equivalent to 5*10+4*1+8*1/10+6*1/100+1*1/1,000 A. 54.861 B. 54.0861 C. 5.4861 D. 0.54861
Circle the composite numbers : 13, 21, 33, 47, 73,
Sorry about the blurry picture but I need help
Reason for expanding religion across North America during Exploration
What does the executive branch do?