import java.util.Scanner; public class State { public static void main(String[] args) { String state; Scanner scan = new Scanner(System.in); // ask the user where they're from System.out.print("What state are you from? "); state = scan.next(); // print a friendly message System.out.println(state + " is a lovely place."); if (state.equals("Kansas")) { System.out.println("That's my home state, too!"); } else if (state.equals("California")) { System.out.println("That's where I was born."); } else { System.out.println("I don't know much about that place."); } } }