diff --git a/Week05/awaitme_mert_colakoglu.py b/Week05/awaitme_mert_colakoglu.py new file mode 100644 index 00000000..10d4a283 --- /dev/null +++ b/Week05/awaitme_mert_colakoglu.py @@ -0,0 +1,13 @@ +def awaitme(func): + """ + A decorator that turns any function into a coroutine. + + :param func: The function to be decorated. + :type func: callable + :return: An asynchronous wrapper of the function. + :rtype: callable + """ + async def _awaitme(*args, **kwargs): + return func(*args, **kwargs) + + return _awaitme