JSFiddle - React, Tailwind, and code Playground
JavaScript
var words = new Array();
//words array key and value pairs: key is #; value is word
words["extemporaneous"] = "Improvised, done without preparation or planning";
words["voracious"] = "Craving or consuming large amounts of food; a voracious appetite";
words["capricious"] = "Impulsive, unpredictable";
words["squander"] = "To waste by spending or using irresponsibly";
words["prattle"] = "To babble meaninglessly, talk in an empty manner";
words["equivocate"] = "Use ambiguous language with a deceptive intent";
var userChoice = prompt("Please select a word from this list to see its definition").toLowerCase();
document.write("<strong>" + userChoice + ".</strong>" + " Definition: " + "<em>" + words[userChoice] + ".</em>");