2023-01-10 09:26:34 +00:00
|
|
|
from botte import request, get
|
|
|
|
|
|
|
|
@get('/age')
|
|
|
|
def age_de():
|
|
|
|
|
|
|
|
name = request.query.name
|
|
|
|
age = request.query.age
|
|
|
|
|
|
|
|
if age > 1:
|
2023-01-10 13:33:19 +00:00
|
|
|
return name + " a " + age + " ans."
|
2023-01-10 09:26:34 +00:00
|
|
|
elif age <= 0:
|
|
|
|
return "Mouai..."
|
|
|
|
else:
|
2023-01-10 13:33:19 +00:00
|
|
|
return name + " a " + age + " an."
|