import java.util.Scanner;
public class Main {
public static void main(String[] args) {
System.out.println("Hello World!");
String[] students = new String[4];
students[0] = "Tiger";
students[1] = "Ray";
students[2] = "Amy";
students[3] = "Macro";
for (int i = 0; i < students.length; i++) {
String gender = sayHi(students[i]);
System.out.println(gender);
}
// TODO Why put it out of loop
String input = null;
// TODO Why !
// TODO Why not "input.equals("bye");"
while (!"bye".equals(input)) {
Scanner sc = new Scanner(System.in);
input = sc.next();
System.out.println("you said " + input);
}
}
public static String sayHi(String name) {
System.out.println("Hello " + name);
if ("Amy".equals(name)) {
return "girl";
} else {
return "boy";
}
}
}