Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Can (a ==1 && a== 2 && a==3) ever evaluate to true?.
i=0,a={valueOf:_=>++i}
- The comma operator evaluates its operands left to right and returns the rightmost operand, the result of which is irrelevant in this case
- The arrow function allows us to omit parenthesis around the function parameters, so any single character variable name works (in this case _)
- The arrow function syntax also allows us to omit the curly braces, and will automatically return the body of the function.
- Automatic Semicolon Injection allows us to omit the trailing ;
There are no comments on this comment yet.
- The comma operator evaluates its operands left to right and returns the rightmost operand, the result of which is irrelevant in this case
- The arrow function allows us to omit parenthesis around the function parameters, so any single character variable name works (in this case _)
- The arrow function syntax also allows us to omit the curly braces, and will automatically return the body of the function.
- Automatic Semicolon Injection allows us to omit the trailing ;