let stocks = {

  PancakeIngredients: ["flour", "eggs 🥚", "sugar", "milk🥛", "butter"],
  
  liquid: ["water 🥛", "coffee ☕", "wine🍷"],

  holder: ["frying pan 🍳"],

  toppings: ["sauce 🥫"],

};


// Function to place an order
var order = (pancakes_name, call_production) => {
  setTimeout(() => {
    console.log(
      `Order placed, ${stocks.PancakeIngredients[pancakes_name]} was selected first amongst the list of ${stocks.PancakeIngredients.length} ingredients`
    );
    call_production();
  }, 2000);
};


// Function for the production process

var production = () => {
  setTimeout(() => {
    console.log("Production has started");
  }, 1000);

  setTimeout(() => {
    console.log("The ingredients has been added to the order, lets bake");
    setTimeout(() => {
      console.log(`add ${stocks.liquid[0]} and stir`);
      setTimeout(() => {
        console.log(`place your ${stocks.holder[0]} on the heater`);
        setTimeout(() => {
          console.log("careful so it doesn't get burnt on fire");
          setTimeout(() => {
            console.log(
              `add some ${stocks.toppings[0]} to give it some unique taste`
            );
            setTimeout(() => {
              console.log("serve pancakes");
            }, 1000);
          }, 1000);
        }, 1000);
      }, 1000);
    }, 1000);
  }, 1000);
};

 order(1, production);