logo

Crowdly

Given the following program, what will be printed if the user enters 6 and 0 ...

✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.

Given the following program, what will be printed if the user enters 6 and 0?

while True:

try:

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

b = int(input("Enter a number: "))

c = a/b

except ZeroDivisionError:

print("b cannot be 0")

except ValueError:

print("Enter a number")

else:

print("result is ", c)

finally:

print("testing...")

Більше питань подібних до цього

Хочете миттєвий доступ до всіх перевірених відповідей на moodle.nu.edu.kz?

Отримайте необмежений доступ до відповідей на екзаменаційні питання - встановіть розширення Crowdly зараз!