Skip to content

Instantly share code, notes, and snippets.

@goodbedford
Last active April 2, 2016 14:08
Show Gist options
  • Select an option

  • Save goodbedford/d47117b8c83edbc3d396a798b8a21c63 to your computer and use it in GitHub Desktop.

Select an option

Save goodbedford/d47117b8c83edbc3d396a798b8a21c63 to your computer and use it in GitHub Desktop.
// order of precedence are the rules for the order in which value gets evaluated
console.log("1 * 2 + 3 * 2 =", 1 * 2 + 3 * 2);
console.log("1 * 2 + 3 * 2 * 5 =", 1 * 2 + 3 * 2 *5);
console.log("5 +1 * 2 + 3 * 2 * 5 =", 5 +1 * 2 + 3 * 2 * 5 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment