Search code examples
python-3.xsublimetext3sublimerepl

python3 input using sublime text 3


I am trying to use the input feature on python for my program. I installed SublimeREPL but I still cant seem to figure out how to provide an input for my program. (coming from a complete beginner)

enter image description here


Solution

  • Using input from within an editor can be tricky. A simple solution would be to run your program from the command line. Open a terminal and change into the directory where your script user_inputs_intro.py is located and type:

    python user_inputs_intro.py
    

    Now, you will see the Tell me something: and should be able to type something that will be echoed back after you press enter.