fix stray paren on increment and decrement (#21036)

made the hints for increment and decrement clearer than they previously were.
This commit is contained in:
myYearOfCode
2018-10-25 10:23:32 -04:00
committed by Paul Gamble
parent fb4e106be0
commit e172adfb9b

View File

@ -18,7 +18,7 @@ JavaScript provides the user with five arithmetic operators: `+`, `-`, `*`, `/`
5 + "foo" // concatenates the string and the number and returns "5foo" 5 + "foo" // concatenates the string and the number and returns "5foo"
"foo" + "bar" // concatenates the strings and returns "foobar" "foo" + "bar" // concatenates the strings and returns "foobar"
_Hint:_ There is a handy <a href='https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Arithmetic_Operators#Increment_(' target='_blank' rel='nofollow'>increment</a>) operator that is a great shortcut when you're adding numbers by 1. _Hint:_ There is a handy <a href='https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Arithmetic_Operators#Increment' target='_blank' rel='nofollow'>increment</a>(++) operator that is a great shortcut when you're adding numbers by 1.
## Subtraction ## Subtraction
@ -34,7 +34,7 @@ _Hint:_ There is a handy <a href='https://developer.mozilla.org/en-US/docs/Web/J
true - 3 // interprets true as 1 and returns -2 true - 3 // interprets true as 1 and returns -2
5 - "foo" // returns NaN (Not a Number) 5 - "foo" // returns NaN (Not a Number)
_Hint:_ There is a handy <a href='https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Arithmetic_Operators#Decrement_(--' target='_blank' rel='nofollow'>decrement</a>) operator that is a great shortcut when you're subtracting numbers by 1. _Hint:_ There is a handy <a href='https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Arithmetic_Operators#Decrement_(--' target='_blank' rel='nofollow'>decrement</a>(--) operator that is a great shortcut when you're subtracting numbers by 1.
## Multiplication ## Multiplication