code is as follows, but it"s not finished yet:
import java.util.Scanner;
import com.sun.org.apache.xerces.internal.util.SynchronizedSymbolTable;
public class Restaurant_system {
public static void main(String[] args) {
/**
*/
/*, */
String[]name = new String[4]; //
String[]dishMegs = new String[4];//
int[]times = new int[4];//
String[]addresses = new String[4];//
int[]states = new int[4];//:01
double[]sumPrices1 = new double[4];//
final double SEND_PRICES = 5.;
double[]sumPrices = new double[4];//
Scanner input = new Scanner(System.in);
int choose;
//
System.out.println(""" ");
System.out.println("********************************************");
System.out.println("1");
System.out.println("2");
System.out.println("3");
System.out.println("4");
System.out.println("5");
System.out.println("6");
System.out.println("********************************************");
System.out.print("\n:");
choose = input.nextInt(); //
switch (choose) {
case 1:
System.out.println("******");
//
int check = 0;//
int check_ok = 0;//
for(;check < name.length;checkPP){//
if (name[check] !=null){//
check_ok += 1;//1
}else{//
break;
}
}
if (check_ok == 4) {//
System.out.println("");
//
}else{//
System.out.print(":");
name[check] = input.next();//
System.out.println("\t\t\t");
System.out.println("1\t\t38.0\t0");
System.out.println("2\t\t20.0\t0");
System.out.println("3\t\t10.0\t0");
}
System.out.print(":");
int number = input.nextInt();
System.out.print(":");
int copies = input.nextInt();
switch (number) {
case 1:
dishMegs[check] = "" +copies + "";
sumPrices1[check] = 38 * copies;
break;
case 2:
dishMegs[check] = "" +copies + "";
sumPrices1[check] = 20 * copies;
break;
case 3:
dishMegs[check] = "" +copies + "";
sumPrices1[check] = 10 * copies;
break;
default:
System.out.println("1-3");
break;
}
if (sumPrices1[check] < 50) {
sumPrices[check] = sumPrices1[check] + SEND_PRICES;
}
System.out.println("1020:)");
boolean time_check_ok = true; //
do {
int time_check = input.nextInt();
if (time_check <= 20 || time_check>= 10) {
times[check] = time_check;
time_check_ok = false;
}else {
System.out.println(":");
}
} while(time_check_ok);
System.out.print(":");
addresses[check] = input.next();
System.out.println("");
System.out.print(":" + dishMegs[check]);
System.out.println(":" + times[check]);
System.out.println(":" + sumPrices1 + ":" + SEND_PRICES + ":" + sumPrices + "");
System.out.println("0:");
//
break;
case 2:
System.out.println("");
break;
case 3:
System.out.println("");
break;
case 4:
System.out.println("");
break;
case 5:
System.out.println("");
break;
case 6:
System.out.println("");
break;
default:
System.out.println("1-6");
break;
}
}
execute the program:
1
:
popped up the following error, checked one side of the code, found nothing wrong, where exactly?