Joined: Thu May 14, 2009 5:49 am Posts: 2 Has thanked: 0 time Have thanks: 0 time
Define a function max() in Javascript that takes two numbers as arguments and returns the largest of them.? Thank you so much for any help. ___________________ market samurai ~ marketsamurai
msi_333
Question subject: Re: Javascript
Posted: Wed Mar 17, 2010 1:08 am
Joined: Tue Mar 27, 2007 10:55 pm Posts: 2103 Location: Earth Has thanked: 39 time Have thanks: 56 time
Code:
function max(var num1 , var num2) { if(num1>num2) return num1; else return num2;
}
_________________ Currenlty programming with : java , html , php , and javascript . (OCJP-6 certified )