Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package oop;
- import java.util.Scanner;
- public class OOP {
- public static void main(String[] args) {
- Scanner imr = new Scanner(System.in);
- System.out.println(" Selamat datang di Gojek kawe! ");
- System.out.println(" Semoga anda puas menggunakan aplikasi ini! ");
- System.out.println("============================================");
- System.out.println("LOGIN");
- System.out.print("Masukkan user : ");
- String username=imr.nextLine();
- System.out.print("Masukkan pass : ");
- int password = imr.nextInt();
- System.out.println("Silahkan pilih menu :");
- System.out.println(" 1.Goride goride an ");
- System.out.println(" 2.Gofood gofood an ");
- System.out.println(" 3.Gosend gosend an ");
- System.out.print("Masukkan pilihan : ");
- int pilih = imr.nextInt();
- switch(pilih){
- case 1:
- System.out.println("Anda memilih menu Goride silahkan pilih");
- System.out.println("1.Kumaha maneh - Atuh weh");
- System.out.println("2.Serah lu - Dah atur bae");
- System.out.println("3.Karepmu - Gas gak rewel");
- System.out.print("Masukkan pilihan : ");
- int pilih1 = imr.nextInt();
- switch(pilih1){
- case 1:
- Goride a =new Goride(" Kumaha maneh " , " Atuh weh " , 2000,7);
- a.tampilGoride();
- break;
- case 2:
- Goride b =new Goride(" Serah lu " , " Dah atur bae " , 2000 , 5);
- b.tampilGoride();
- break;
- case 3:
- Goride c = new Goride(" Karepmu " , " Gas gak rewel " , 2000 , 3);
- c.tampilGoride();
- break;
- }
- break;
- case 2:
- System.out.println(" Anda memilih menu Gofood silahkan pilih : ");
- System.out.println( " 1.Chicken Honey Mustard " );
- System.out.println( " 2.Spaghetti Aglio Olio " );
- System.out.println( " 3.Roasted Quail Stuffed with Egg risotto " );
- System.out.print("Masukkan pilihan : ");
- int pilih2 = imr.nextInt();
- switch(pilih2){
- case 1:
- Gofood a =new Gofood( " Chicken Honey Mustard " , 55000);
- a.tampilGofood();
- break;
- case 2:
- Gofood b =new Gofood( " Spaghetti Aglio Olio " , 59000);
- b.tampilGofood();
- break;
- case 3:
- Gofood c =new Gofood( " Roasted Quail Stuffed with Egg risotto " , 70000);
- c.tampilGofood();
- break;
- }
- break;
- case 3:
- System.out.println("Anda memilih menu Goride silahkan pilih");
- System.out.println( "1.Barang Aku ");
- System.out.println( "2.Barang Kamu ");
- System.out.println( "3.Barang Kita ");
- System.out.print("Masukkan pilihan : ");
- int pilih3 = imr.nextInt();
- switch(pilih3){
- case 1:
- Gosend a =new Gosend(" Barang Aku " , 5.5 , 1.28);
- a.tampilGosend();
- break;
- case 2:
- Gosend b =new Gosend(" Barang Kamu ", 5.5 , 2);
- b.tampilGosend();
- break;
- case 3:
- Gosend c =new Gosend(" Barang Kita ", 5.5 , 3.5);
- c.tampilGosend();
- break;
- }
- System.out.println("Terima Kasih telah menggunakan aplikasi ini :) ");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement