Generate random sentence from lists
function getRandomInt(max) { return Math.floor(Math.random() * Math.floor(max)); } function generateName(adjectives, animals) { return adjectives[getRandomInt(adjectives.length)] + " " + animals[getRandomInt(animals.length)]; } generateName(["skinny", "fat", "smelly", "generous"], ["cat", "dog", "fish", "horse"])