Arrow functions, the basics Flashcards

1
Q

let double = (n) => n * 2;

//how can this be shortened?

A

let double = n => n * 2;

No parenthesis needed if only single argument

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

in a arrow function If there are no ______, parentheses are empty,

A

arguments

How well did you know this?
1
Not at all
2
3
4
5
Perfectly