Menubased Program in JAVA : HOTEL Menu

Write a program (WAP) in JAVA to Menu-based selection for Hotel Menu Program to Order Dishes.
Hotel Menu Order Dishes

Write a program (WAP) in JAVA to Menu-based selection for Hotel Menu Program to Order Dishes.

import java.util.Scanner;
public class HotelMenu
{
  public static void main(String[] args){
  Scanner scan = new Scanner(System.in);

  System.out.println("Welcome to S3hotel.com(All types of INDIAN food available here) ");
  System.out.println();

  //Menu Creation
  while(true)
  {
    System.out.println("Enter 1 : To order South Indian Dish");
    System.out.println("Enter 2 : To order North Indian Dish");
    System.out.println("Enter 3 : To order Rajasthani Dish");
    System.out.println("Enter 4 : To order Gujrati Dish");
    System.out.println("Enter 5 : To order Bengali Dish");
    System.out.println("Enter 6 : To order Desserts");
    System.out.println("Enter 7 : To Exit");

    System.out.println();
    System.out.println("Enter your choice::");
    int choice = scan.nextInt();

   switch(choice)
   {
     case 1:
     System.out.println("Welcome to South Indian Food Court");
     southIndianFood();
     break;
    
     case 2:
     System.out.println("Welcome to North Indian Food Court");
     northIndianFood();
     break;
    
     case 3:
     System.out.println("Welcome to Rajasthani Food Court");
     rajasthaniFood();
     break;
    
     case 4:
     System.out.println("Welcome to Gujrati Food Court");
     gujratiFood();
     break;
    
     case 5:
     System.out.println("Welcome to Bengali Food Court");
     bengaliFood();
     break;
    
     case 6:
     System.out.println("Welcome to Desserts Food Court");
     desserts();
     break;
    
     case 7:
     System.out.println("Thanks for ordering here \nVisit Again");
     System.exit(0);
     break;
    
     default:
     System.out.println("Incorrect input!! Please re-enter a Correct choice from our menu");
   }
  }
 }

 public static void southIndianFood()
 {
  System.out.println("You get:");
  System.out.println("Idli : 2 Pieces:");
  System.out.println("Butter Cheese Dosa : 1 Pieces:");
  System.out.println("Vada : 2 Pieces:");
 }

 public static void northIndianFood()
 {
  System.out.println("You get:");
  System.out.println("Chole Bhature : 2 Pieces:");
  System.out.println("Litti Chokha : 4 Pieces:");
 }

 public static void rajasthaniFood()
 {
  System.out.println("You get:");
  System.out.println("Dal Baati Churma");
  System.out.println("Laal maas");
  System.out.println("Methi Bajra puri");
 }

 public static void gujratiFood()
 {
  System.out.println("You get:");
  System.out.println("Dhokla : 2 pieces");
  System.out.println("Khandvi");
  System.out.println("Methi ka Thepla");
 }

 public static void bengaliFood()
 {
  System.out.println("You get:");
  System.out.println("Maach Bhaat");
  System.out.println("Aalu Luchi");
 }

 public static void desserts()
 {
  System.out.println("You get:");
  System.out.println("Rasmalai");
  System.out.println("Rasgulla : 2 Pieces");
  System.out.println("Emarti : 2 Pieces");
  System.out.println("Gajar ka halwa");
 }

}

Sample Outputs

  When the above JAVA program is compiled or executed, it will produce the following results,
1. 
South Indian Food Output

2.
Nouth Indian Food Output

3.
EXIT Output


Must Read :-

  1. Blogger Tutorial
  2. C Programs
  3. C++ Programs
  4. Java Programs
  5. Python Programs
  6. Programming Notes 
  7. Questions & Answers
  8. My Codes : HTML, CSS & JS

About the author

Sarthak Mund S3
◕‿◕कर दिखाओ कुछ ऐसा की दुनिआ करना चाहे आपके जैसा◕‿◕

3 comments

  1. debashish
    debashish
    really helpful program
    1. Sarthak Mund S3
      Sarthak Mund S3
      Thnqqhhh :)
  2. Fashionothon.com
    Fashionothon.com
    fashionothon give more than 50% discount on men fashion, women fashion, kids wear and more branded product.
    shop now
    click here!