+ 3

i want to get input age as 17 and write my age is 17 in python

i want to get input age as 17 and write my age is 17 in python sir, i tried but it didnt possible anyone help plz? age = input("age : ") print("my age is") + str (age)

23rd Nov 2021, 1:44 PM
vijay
3 Answers
+ 6
print(f"my age is {age}" ) print("my age is " , age)
23rd Nov 2021, 1:52 PM
Pariket Thakur
Pariket Thakur - avatar
+ 3
The part "..." + age needs to be inside the print function print("my age is " + age)
23rd Nov 2021, 1:58 PM
Lisa
Lisa - avatar
+ 2
age = input("age : ") message = "my age is " + age print(message)
23rd Nov 2021, 8:43 PM
Gordon
Gordon - avatar