About 8,910,000 results
Open links in new tab
  1. python - Creating if/else statements dependent on user input

    I'm trying to create a simple script that will will ask a question to which the user will input an answer (Or a prompt with selectable answers could appear?), and the program would output a …

  2. python - How can I read inputs as numbers? - Stack Overflow

    Dec 8, 2013 · python python-3.x python-2.7 input int edited Apr 28, 2019 at 1:05 smci 34.1k 21 117 152

  3. Why do I get "NameError: name '...' is not defined ... - Stack Overflow

    TL;DR input function in Python 2.7, evaluates whatever your enter, as a Python expression. If you simply want to read strings, then use raw_input function in Python 2.7, which will not evaluate …

  4. python - How to allow VS Code to take input from users? - Stack …

    The two settings above should allow you to A) Enter input inside of the integrated terminal and B) Select which python interpreter code-runner should execute easily using existing commands.

  5. python - Getting a hidden password input - Stack Overflow

    Accepts backspace input Outputs * character (DEC: 42 ; HEX: 0x2A) instead of the input character Demerits: Works on Windows only The function secure_password_input() returns …

  6. python - How to redo an input if user enters invalid answer - Stack ...

    Closed last year. I'm new to programming, and I was wondering how I can repeat an input section, if the user types in invalid data. I want the application to just repeat the input section, instead …

  7. How to define default value if empty user input in Python?

    Here is the code that user can enter value: input = int(raw_input("Enter the inputs : ")) Here the value will be assigned to a variable input after entering the value and hitting Enter. Is there any …

  8. python - How to read keyboard input? - Stack Overflow

    As blocking on keyboard input (since the input() function blocks) is frequently not what we want to do (we'd frequently like to keep doing other stuff), here's a very-stripped-down multi-threaded …

  9. python - How can I check if string input is a number? - Stack …

    I have found that some Python libraries use assertions to make sure that the value supplied by the programmer-user is a number. Sometimes it's good to see an example 'from the wild'.

  10. How do I do simple user input in python? - Stack Overflow

    How do I do simple user input in python? [duplicate] Asked 14 years, 8 months ago Modified 7 years, 2 months ago Viewed 97k times