My implementation :
public class NewClass {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
System.out.println("Input your place and date birth : ");
String birth = in.nextLine();
}
}
And I will input MindStick, 25 Dec 2015. The problem how to change my input from string to int, and how to take only the year. So I can use for
if (2015 - year < 20 ) {
System.out.println ("You are teen");
}
David Miller
20-Dec-2015