Multiple ChoiceBeginner 30s
Default Parameters — Expressions
Choose the best answer for: default parameter values
Options
- 1Defaults use the || operator, so falsy values drop
- 2function f(x = 5) uses 5 if x is undefined
- 3Defaults only work with objects, not other types
- 4Defaults must be numbers, other literals are errors
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.