Provides "prompt" function with timeout