Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript function return boolean

function  func(){
  return true;
}

isBool = func();
console.log(typeof (isBool));   // output - string


let isBool = func();
console.log(typeof (isBool));   // output - boolean
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #function #return #boolean
ADD COMMENT
Topic
Name
1+8 =