randomly sample from array ks code example Example: js random string from array const randomElement = array[Math.floor(Math.random() * array.length)];