03_zemljevid_ovir
This commit is contained in:
13
01_kolicina_goriva/naloga.py
Normal file
13
01_kolicina_goriva/naloga.py
Normal file
@@ -0,0 +1,13 @@
|
||||
weight = int(input("Vnesi težo tovora: "))
|
||||
fuel_weight = 0
|
||||
actual_fuel_weight = 0
|
||||
|
||||
while weight > 0:
|
||||
weight = weight // 3 - 2
|
||||
fuel_weight += 1
|
||||
if weight <= 0:
|
||||
continue
|
||||
actual_fuel_weight += weight
|
||||
|
||||
print("Teža goriva:", fuel_weight)
|
||||
print("Dejanska teža goriva:", actual_fuel_weight)
|
||||
Reference in New Issue
Block a user