import asyncio

async def x():
    while True:
        await asyncio.sleep(0.3)
        print('oIo dick')

async def y():
    while True:
        await asyncio.sleep(1)
        print(')( cunt')

async def main():
	try:
	    await asyncio.wait_for(asyncio.gather(x(), y()), timeout=4.5)
	except:
	    print('timeout')

loop = asyncio.get_event_loop()
loop.run_until_complete(main())

