Answers for "python time limit for input"

0

python time limit for input

import time
from threading import Thread

answer = None

def check():
    time.sleep(2)
    if answer != None:
        return
    print("Too Slow")

Thread(target = check).start()

answer = input("Input something: ")
Posted by: Guest on September-30-2021

Python Answers by Framework

Browse Popular Code Answers by Language