import java.util.Scanner; public class Refresher { public static void main (String[] args) { String name; Scanner kb = new Scanner(System.in); System.out.print("What's your name?"); name = kb.next(); if (!name.equals("Josh")) { for (int n = 1; n <= 10; n = n + 1) { System.out.println(name); } } else if (name.equals("Josh")) { for (int n = 1; n <= 5; n = n + 1) { System.out.println(name); } } } }