2026fa_cse160/homework/homework04/input/input02.py

8 lines
293 B
Python

print("This program converts the input to an integer\n")
data1 = input("Enter an integer value for data1: ")
print(f"The type of data1 is {type(data1)} at input")
data1 = int(data1)
print(f"The type of data1 is {type(data1)} after conversion to int")
print(f"The value of data1 is {data1}")