Javascript Functions

(Assignments here & here)


Problem Set

Blog Question

//Saves the returned value of the function "doSomething" 
var savedValue = doSomething(x)
  • Functions are used to preform a task or calculate a value.
 //determines if the value is even and returns this information 
function isEven(num){     
if(num % 2 == 0){         
return true;     
return false; } 

Leave a Reply

Your email address will not be published. Required fields are marked *