answer = input('What is your name?')
name = input("Who are you? ")
print("Welcome", name)
# to greet somebody with their name you do like the following
def greet(name):
print(f"Hello, {name} How do you do?")
greet("John Due") # you will get Hello, John Due How do you do?
# if you wanna get the input from the user you can do that too!
name = input("Please enter your name: ")
greet(name) # this takes the input from the user and then greets the user
a = input("Enter a number: ")
a = int(a) # Convert a to an Integer(if possible)
print(type(a))
make_a_variable_name = input("Put whatever question, or prompt as Python calls it, that the person will answer here.")
num = tuple(input("Enter number: "))
# output
print(num)
#Function in python
def identity(age):
print("You are "+str(age)+" Years old")
identity(input("Type your age: "))
def id(name):
print("Hello "+name+"."+"You are our valued customer")
print("Have a nice Day "+name)
id(input("Type your name: "))
# if you want to use the input method to get the user info more
# than one time then you should make two function.
# In one function you can't get the multiple results.if anyone can find
# please add to greeper ans.
>>> name = input('Enter your name: ')
Enter your name: Ranjeet
>>> name
Ranjeet