I am very noob at Python. and also noob in English, Sorry. I want to input mixed data type in one line in 2d list.
n = input("how many people? : ")
data = []
for i in range(n):
data.append(list(map(str, input("Enter name, height(cm), weight(kg) :").split())))
if i enter code
2
John 185 80
Tom 172 71
shows me
[['John', '185', '80'],['Tom', '172', '71']]
but i want input name in str, others in int, output like this.
[['John', 185, 80],['Tom', 172, 71]]
but if i change
data.append(list(map(str, input("Enter name, height(cm), weight(kg) :").split())))
this line of str to int, i can't input name because of error. ToT