
"""simple docstring"""


from datetime import date

import requests

lowerCAmelCase								=						"""https://api.carbonintensity.org.uk/intensity"""






def        lowerCAmelCase_       (		)       ->str:
			lowerCamelCase__     :					Any		=requests.get(snake_case_      ).json()['data'][0]
			return last_half_hour["intensity"]["actual"]






def        lowerCAmelCase_       (		snake_case_		:      Dict							,   snake_case_		:      Optional[int]      )       ->list:
			return requests.get(f"""{BASE_URL}/{start}/{end}"""      ).json()["data"]


if __name__ == "__main__":
							for entry in fetch_from_to(start=date(20_20, 10, 1), end=date(20_20, 10, 3)):
														print("""from {from} to {to}: {intensity[actual]}""".format(**entry))
							print(f"""{fetch_last_half_hour() = }""")

"""simple docstring"""


from math import cos, sin






def        lowerCAmelCase_       (		snake_case_		:      float      )       ->list[list[float]]:
			lowerCamelCase__     :					List[Any]		=float(snake_case_      )
			return [[scaling_factor * int(x == y      ) for x in range(2      )] for y in range(2      )]






def        lowerCAmelCase_       (		snake_case_		:      float      )       ->list[list[float]]:
			lowerCamelCase__	,    lowerCamelCase__     :					Union[str, Any]		=cos(snake_case_      ), sin(snake_case_      )
			return [[c, -s], [s, c]]






def        lowerCAmelCase_       (		snake_case_		:      float      )       ->list[list[float]]:
			lowerCamelCase__	,    lowerCamelCase__     :					Optional[Any]		=cos(snake_case_      ), sin(snake_case_      )
			lowerCamelCase__     :					Dict		=c * s
			return [[c * c, cs], [cs, s * s]]






def        lowerCAmelCase_       (		snake_case_		:      float      )       ->list[list[float]]:
			lowerCamelCase__	,    lowerCamelCase__     :					str		=cos(snake_case_      ), sin(snake_case_      )
			lowerCamelCase__     :					Dict		=c * s
			return [[2 * c - 1, 2 * cs], [2 * cs, 2 * s - 1]]


print(f"""    {scaling(5) = }""")
print(f"""  {rotation(45) = }""")
print(f"""{projection(45) = }""")

print(f"""{reflection(45) = }""")