Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js array random find

const months = ["January", "February", "March", "April", "May", "June", "July"];

const random = Math.floor(Math.random() * months.length);
console.log(random, months[random]);
 Run code snippet
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #js #array #random #find
ADD COMMENT
Topic
Name
8+3 =