from aiogram import Bot, Dispatcher, executor, types
import time
Token = "5962272909:AAEXM4bM-JmDlL0hhjUl75HMU8FQYqDssA8"
bot = Bot(token=Token)
dp = Dispatcher(bot=bot)
isDelieved = True
MSG = "Привет"
MSG2 = "hi"
@dp.message_handler(commands='test')
async def test(message: types.message):
user_id = message.from_user.id
n = 1
a = 1
b = 0
if n == a:
await MSG2.delete()
await bot.send_message(MSG)
n = b
time.sleep(5)
if n == b:
await MSG.delete()
await bot.send_message(MSG2)
if __name__ == '__main__':
executor.start_polling(dp)