Answers for "javascript function with condition in parameter"

0

javascript function with condition in parameter

function myFuntionName(condition) {
	//this example uses an if statement
  	if (condition) {
    	//code 
    }
}

//call the function
let a = 8;
myFunctionName(a > 7);//a > 7 is converted into boolean before it is processed in the function
Posted by: Guest on April-01-2020

Code answers related to "javascript function with condition in parameter"

Code answers related to "Javascript"

Browse Popular Code Answers by Language