Skip to content

Instantly share code, notes, and snippets.

@bored-engineer
Last active December 23, 2015 01:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bored-engineer/6563994 to your computer and use it in GitHub Desktop.
Save bored-engineer/6563994 to your computer and use it in GitHub Desktop.
Pick a random quote relating to programming, and send to stdout.
// Create array of possible quotes
var quotes = [
"There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies and the other way is to make it so complicated that there are no obvious deficiencies. — C.A.R. Hoare, The 1980 ACM Turing Award Lecture"
];
// Get a random quote index
var i = Math.floor(Math.random()*quotes.length);
// Print a random quote
console.log(quotes[i]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment