function addRandomGreeting() {
  const greetings = ['Hello!', 'مرحبا', 'Bonjour!', 'Nah How?'];

  // Pick a random greeting.
  const greeting = greetings[Math.floor(Math.random() * greetings.length)];

  // Add it to the page.
  const greetingContainer = document.getElementById('greeting-container');
  greetingContainer.innerText = greeting;
}
/**
 * Adds a random greeting to the page.
 */
Adds a random greeting to the page.
Adds a random greeting to the page .
function addRandomGreeting() {
  const greetings = ['Hello!', 'مرحبا', 'Bonjour!', 'Nah How?'];
  const greeting = greetings[Math.floor(Math.random() * greetings.length)];
  const greetingContainer = document.getElementById('greeting-container');
  greetingContainer.innerText = greeting;
}
function addRandomGreeting ( ) { const greetings = [ 'Hello!' , 'مرحبا', 'Bo n our!', 'Na h How?']; const greeting = greetings [ Math . floor ( Math . random ( ) * greetings . length ) ] ; const greetingContainer = document . getElementById ( 'greeting-container' ) ; greetingContainer . innerText = greeting ; }
Adds a random greeting to the page.
Adds a random greeting to the page .
// Pick a random greeting. // Add it to the page.