import java.util.Scanner;
import java.util.*;
import java.text.*;
public class Regist {
public static void main (String [] args) {
Scanner input = new Scanner(System.in);
DecimalFormat format = new DecimalFormat("$0.00");
String[] myMenu = {"1. Hot Dog", "2. Hamburger", "3. Soda", "4. Chips", "5. Ice Cream", "6. Shave Ice", "7. Cookie", "8. Plate Lunch", "9. French Fries", "10. Shake", "11. Order Complete"};
String[] pluralMenu = {"Hot Dogs", "Hamburgers", "Sodas", "Chips", "Ice Creams", "Shave Ice", "Cookies", "Plate Lunches", "French Fries", "Shakes"};
String[] selectedItems = new String[10];
double[] price = {2.50, 3.00, 1.25, 1.50, 2.50, 2.00, 1.00, 5.00, 2.50, 3.00};
int[] itemNumber = new int[10];
int totalItems = 0;
double prices = 0;
int decision;
String choice = "";
do {
for (String a: myMenu) {
System.out.println(a);
}
System.out.print("Please select your choice: ");
decision = input.nextInt() - 1;
if (decision != 10) {
if (itemNumber[decision] < 1 ) {
totalItems++;
}
itemNumber[decision] = itemNumber[decision] + 1;
prices = prices + price[decision];
if( itemNumber[decision] == 1) {
selectedItems[decision] = myMenu[decision].substring(2);
} else if (itemNumber [decision] > 1) {
selectedItems[decision] = pluralMenu[decision];
}
}
} while (decision != 10);
for (int i = 0; i != 10; i++) {
if (selectedItems[i] != null) {
choice = choice + " (" + itemNumber[i] + ")" + selectedItems[i];
}
}
System.out.println ("Your order contains: " + choice);
System.out.println ("Your order price is: " + format.format(prices));
}