Ответ:
a = int(input("a = "))
b = int(input("b = "))
c = int(input("c = "))
print("Числа, в порядке возрастания: ",end="");
if (a<=b) and (a<=c) and (b<=c):
print(a,' ',b,' ',c)
elif (a<=b) and (a<=c) and (c<=b):
print(a,' ',c,' ',b)
elif (b<=a) and (b<=c) and (a<=c):
print(b,' ',a,' ',c)
elif (b<=a) and (b<=c) and (c<=a):
print(b,' ',c,' ',a)
elif (c<=a) and (c<=b) and (a<=b):
print(c,' ',a,' ',b)
elif (c<=a) and (c<=b) and (b<=a):
print(c,' ',b,' ',a)
Объяснение:
Условный оператор определяет порядок вывода чисел
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ:
a = int(input("a = "))
b = int(input("b = "))
c = int(input("c = "))
print("Числа, в порядке возрастания: ",end="");
if (a<=b) and (a<=c) and (b<=c):
print(a,' ',b,' ',c)
elif (a<=b) and (a<=c) and (c<=b):
print(a,' ',c,' ',b)
elif (b<=a) and (b<=c) and (a<=c):
print(b,' ',a,' ',c)
elif (b<=a) and (b<=c) and (c<=a):
print(b,' ',c,' ',a)
elif (c<=a) and (c<=b) and (a<=b):
print(c,' ',a,' ',b)
elif (c<=a) and (c<=b) and (b<=a):
print(c,' ',b,' ',a)
Объяснение:
Условный оператор определяет порядок вывода чисел