Repozitář ke Gitové přednášce JKSP2021
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
a = int(input("Zadej prvni cislo"))
|
|
|
|
b = int(input("Zadej druhe cislo"))
|
|
|
|
|
|
|
|
operator = input("Zadej operátor")
|
|
|
|
if operator == '+':
|
|
|
|
print("Součet je", a + b)
|
|
|
|
elif operator == '-':
|
|
|
|
print("Rozdíl je", a - b)
|
|
|
|
elif operator == '*':
|
|
|
|
print("Součin je", a * b)
|
|
|
|
elif operator == '/':
|
|
|
|
print("Podíl je", a // b)
|
|
|
|
elif operator == '^':
|
|
|
|
print("Mocnina je", a ^ b)
|
|
|
|
else:
|
|
|
|
print("Tento operátor neznám")
|