-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path4-Inputs.py
28 lines (20 loc) · 927 Bytes
/
4-Inputs.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Type conversion
# Name = input("Enter your Name ")
# Age = int(input("Enter your Age"))
#
# print(Name)
# print(Name +' is '+ (Age) + ' is old') #concatnate string to string
# print(Name +' is '+ str(Age) + ' is old')
# Without type conversion
# Name = input("Enter your name")
# age = int(input("Enter your your age"))
# height = float(input('Enter your weight'))
Name = 'Nishanth'
age = 21
height = 6.1
#print("{0} is {1} years is old and Height {2} inch " .format(Name, age, weight))
print("%s is %i years is old and Height is %f inch " %(Name, age, height))
print("%s is %s years is old and Height is %s inch " %(Name, age, height)) #--> Fully in String
print("%r is %r years is old and Height is %r inch " %(Name, age, height)) #--> Debugging Information
# F - string
print(f" \n {Name} is {age} years is old and Height is {height} inch")