let fruits = ["Apple", "Banana", "Mango", "Orange"]; // array
let index = Math.floor(Math.random() * fruits.length); // random index
console.log(fruits[index]); // result
function choose(choices) {
var index = Math.floor(Math.random() * choices.length);
return choices[index];
}