java - Entering int in a string variable -
i ask user enter name(string) , age(int), if user enters number in name space "crashes". can stop program crashing. im using java.
are casting input int, or leaving string? once take in input need convert string int. int age = integer.parseint(ageinput);
Comments
Post a Comment