Answers for "prompt in python"

1

pythn programme for adding user unputs

# Store input numbers
num1 = input('Enter first number: ')
num2 = input('Enter second number: ')

# Add two numbers
sum = float(num1) + float(num2)

# Display the sum
print('The sum of {0} and {1} is {2}'.format(num1, num2, sum))
Posted by: Guest on July-01-2020
3

how to accept input from the user in python

# if you want to ask the user to input anything, use the keyword "input"

# example

a = input("What is your name") # the user will be prompted to answer the question 

print(a) # this allows the user to actaully see the question or anything
Posted by: Guest on June-13-2020
-1

python launch prompt

$ python3.9
Python 3.9 (default, June 4 2019, 09:25:04)
[GCC 4.8.2] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>
Posted by: Guest on September-06-2021

Python Answers by Framework

Browse Popular Code Answers by Language