title: JavaScript Foreach value in array to string
body: <p>Looking for some help in JS. I have an array of array's</p>
  
  <pre><code>var totalOrder = []
  function CafeService(meal, starter, main, dessert){//takes value from text box input
  var customerOrder = [meal, starter, main, dessert]
  
  totalOrder.push(customerOrder ); 
  }
  </code></pre>
  
  <p>This is populating correctly.There can be a unlimited amount of orders. I want to check through the order before sending to the kitchen. How can I put each index in the array into strings e.g. to populate the below:</p>
  
  <pre><code>var mealTime;
  var mealStarter;
  var mealMain;
  var mealDessert;
  </code></pre>
  
  <p>I expect I need to do this with a for each? </p>
  
  <pre><code>foreach (customerOrder in totalOrder){
      var mealTime; //how to populate
      var mealStarter;
      var mealMain;
      var mealDessert;
  }
  </code></pre>
  
  <p>EDIT Total Order with one customers order:</p>
  
  <pre><code>var totalOrder = ["Breakfast","Coffee","Toast","Apple"]
  </code></pre>