function displayQuestion() {

  if (time == 0) {
    updateTime();
    return;
  }

  intervalId = setInterval(updateTime, 1000);

  questionEl.textContent = questions[questionIndex].question;

  multipleChoiceEl.innerHTML = "";
  questionResultEl.innerHTML = "";

  var choices = questions[questionIndex].choices;
  var choicesLenth = choices.length;

  for (var i = 0; i < choicesLenth; i++) {
    var questionListItem = document.createElement("li");
    questionListItem.className = ("choices-list");
    questionListItem.textContent = choices[i];
    multipleChoiceEl.append(questionListItem);
  }
}
//function to display the question and choices on screen
function to display the question and choices on screen
function to display the question and choices on screen
function displayQuestion() {
  if (time == 0) {
    updateTime();
    return;
  }
  intervalId = setInterval(updateTime, 1000);
  questionEl.textContent = questions[questionIndex].question;
  multipleChoiceEl.innerHTML = "";
  questionResultEl.innerHTML = "";
  var choices = questions[questionIndex].choices;
  var choicesLenth = choices.length;
  for (var i = 0; i < choicesLenth; i++) {
    var questionListItem = document.createElement("li");
    questionListItem.className = ("choices-list");
    questionListItem.textContent = choices[i];
    multipleChoiceEl.append(questionListItem);
  }
}
function displayQuestion ( ) { if ( time == 0 ) { updateTime ( ) ; return ; } intervalId = setInterval ( updateTime , 1000 ) ; questionEl . textContent = questions [ questionIndex ] . question ; multipleChoiceEl . innerHTML = "" ; questionResultEl . innerHTML = "" ; var choices = questions [ questionIndex ] . choices ; var choicesLenth = choices . length ; for ( var i = 0 ; i < choicesLenth ; i ++ ) { var questionListItem = document . createElement ( "li" ) ; questionListItem . className = ( "choices-list" ) ; questionListItem . textContent = choices [ i ] ; multipleChoiceEl . append ( questionListItem ) ; } }
function to display the question and choices on screen
function to display the question and choices on screen