Time Delay Function In Python Definition Syntax Error