JS Built-ins
BooleantoStringbeginner

Boolean.toString() β€” Boolean(1).toString()

πŸ“– Usage Example
false.toString()  // β†’ 'false'

false.toString() always returns the string 'false'.

Boolean(1).toString()

Boolean(1) is true, so Boolean(1).toString() returns 'true'.

Challenge: Verify the result.

πŸ’‘ Hints (1)
  • β€’ Convert to boolean first, then call toString().