I also need to convert my answer into javascript code that displays the largest value.
views:
119answers:
2
A:
I guess you just need something on the lines of:
var mx = list[0];
for (i=1; i<length(list); i++)
mx = Math.max(mx, list[i])
alert(mx)
nico
2010-08-01 17:29:43
Alternatively, `Math.max.apply(null, list)`
CD Sanchez
2010-08-02 00:30:25
@Daniel: good one! Did not know about the apply function
nico
2010-08-02 07:17:43