Water for the Ride

Before a bike ride, it helps to estimate how much water you will need. The rule is simple: each hour of cycling uses 0.5 litres of water. Write a function litres that takes the time time in hours and returns the whole number of litres, rounded down.

Примеры

Ввод
2
Вывод
1
Ввод
1
Вывод
0
Ввод
3
Вывод
1

Нужно реализовать

def litres(time: int) -> int:

Теги

math
PostgreSQLv16

Taispeánfar toradh do chóid anseo

Visible tests
1
Input
2
Expected1
2
Input
1
Expected0
3
Input
3
Expected1
4
Input
6.7
Expected3
5
Input
0
Expected0
6
Input
999999
Expected499999
Focus radio
Paused · SomaFM · Fluid