// how to generate random words from an array const Coins = ["Heads","Tails"] let Generate = Math.floor((Math.random() * Coins.length)); console.log(Coins[Generate]) // this will print the outcome