[JavaScript] quote author repeat

2022. 9. 11. 13:29JavaScript

⚡️<index.html>

⚡️<quote.js>

quotes[Math.floor(Math.random() * quotes.length)]
  1. Math.random : 0 "이상" 1 "미만" 값
  2. Math.floor : 소수점 내림