// // Review for Java // // Goal: read in three names and out in reverse order // import java.util.Scanner; public class ReverseNames { public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.print("Type the 1st name: "); String name1 = input.nextLine(); System.out.print("Type the 2nd name: "); String name2 = input.nextLine(); System.out.print("Type the 3rd name: "); String name3 = input.nextLine(); System.out.println(name3 + ", " + name2 + ", " + name1); } }