Python- Day 1
2 min readJul 11, 2024
To Check if the install
python
print("hello")
input
input("What is your name?")
print("Hello " + input("What is your name?"))
>>
What is your name?Nidhi
Hello Nidhi
variable
#To print name stored in variable
name = input("What is your name?")
print("Hello " + name)
#To print length
length = len(name)
print(length)
# Our Code
name = input("What is your name?")
length = len(name)
print("Hello " + name)
print(length)
>>
What is your name?Nidhi
Hello Nidhi
5
Note: Variable holds the latest value in the code
PROJECT 1: Welcome to Band Generator
print("Welcome to Band Generator")
name = input("What is your city name?\n")
pet = input("What is your pet name?\n")
print("You Band name is " + name + " " + pet)
>>
Welcome to Band Generator
What is your city name?
CA
What is your pet name?
Drogo
You Band name is CA Drogo
If you found this guide helpful then do click on 👏 the button.
Follow for more Learning like this 😊
If there’s a specific topic you’re curious about, feel free to drop a personal note or comment. I’m here to help you explore whatever interests you!