import java.io.*;
class Switch2
{
public static void main (String[]args) throws IOException
{
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Create By ahmad sakhowi amin");
System.out.println("-------- 2011470130 -------------");
System.out.println("---------------------------");
System.out.println("^^^^^ Menu Makanan Muji Jaya ^^^^^^");
System.out.println("--------------------------");
System.out.println("^^^^^^^^^^^^^^^^^^^^^^^^^^");
System.out.println("** 1. Soto Ayam **");
System.out.println("** 2. Gule Kambing **");
System.out.println("** 3. Nasi Goreng **");
System.out.println("** 4. Bakso **");
System.out.println("**************************");
System.out.print("Masukkan Menu Pilihan Anda [1-4] = ");
String k=in.readLine();
int pilihan = Integer.parseInt(k);
System.out.print("Menu Pilihan Anda Adalah ");
switch(pilihan)
{
case 1:
System.out.println("Soto Ayam");
break;
case 2:
System.out.println("Gule Kambing");
break;
case 3:
System.out.println("Nasi Goreng");
break;
case 4:
System.out.println("Bakso");
break;
default:
System.out.println(+pilihan);
}
}}
class Switch2
{
public static void main (String[]args) throws IOException
{
BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
System.out.println("Create By ahmad sakhowi amin");
System.out.println("-------- 2011470130 -------------");
System.out.println("---------------------------");
System.out.println("^^^^^ Menu Makanan Muji Jaya ^^^^^^");
System.out.println("--------------------------");
System.out.println("^^^^^^^^^^^^^^^^^^^^^^^^^^");
System.out.println("** 1. Soto Ayam **");
System.out.println("** 2. Gule Kambing **");
System.out.println("** 3. Nasi Goreng **");
System.out.println("** 4. Bakso **");
System.out.println("**************************");
System.out.print("Masukkan Menu Pilihan Anda [1-4] = ");
String k=in.readLine();
int pilihan = Integer.parseInt(k);
System.out.print("Menu Pilihan Anda Adalah ");
switch(pilihan)
{
case 1:
System.out.println("Soto Ayam");
break;
case 2:
System.out.println("Gule Kambing");
break;
case 3:
System.out.println("Nasi Goreng");
break;
case 4:
System.out.println("Bakso");
break;
default:
System.out.println(+pilihan);
}
}}
0 comments:
Posting Komentar