staticwebapp-hhv-tormakrist.../api/hanyadikhetvan/__init__.py
Torma Kristóf 3e7cb0f18a
Some checks failed
continuous-integration/drone/push Build is failing
update with new start of term
2022-12-27 13:42:24 +01:00

13 lines
339 B
Python

from math import floor
from datetime import date
from urllib import request
import azure.functions as func
def main(req: func.HttpRequest) -> func.HttpResponse:
startdate = date(2023, 2, 27)
currentweek = floor((date.today() - startdate).days / 7)
return func.HttpResponse(
str(currentweek),
status_code=200)