Answers for "Javascript convert boolean to a number"

0

Javascript convert boolean to a number

console.log(+true);  // Return: 1
console.log(+false); // Return: 0
Posted by: Guest on September-14-2021

Code answers related to "Javascript convert boolean to a number"

Code answers related to "Javascript"

Browse Popular Code Answers by Language