I need to convert user input to int. Below is what I have written so far which is not working out. It only accepts int. the end goal is to
input
int
Apart from the other answers, you can use round() function:
round()
i = input("Enter any value: ") print(round(i))
But if you want to simply cut the decimal part, you can use math lib and floor():
floor()
import math i = input("Enter any value: ") print(math.floor(i))