Never been to TextSnippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)

Prototype based Javascript min(...), max(...) functions (See related posts)


Use cases
min(1,-1,2,3,4) == -1
max(2,10) == 10

function min() {
 return $A(arguments).min();
}

function max() {
 return $A(arguments).max();
}


Comments on this post

ankurjain posts on Dec 06, 2006 at 23:30
Has any one found the solution for this ?

You need to create an account or log in to post comments to this site.


Related Posts