Just another Perl shrine | |
PerlMonks |
Re^2: Finding the max()/min()by etcshadow (Priest) |
on Nov 12, 2004 at 22:12 UTC ( [id://407547]=note: print w/replies, xml ) | Need Help?? |
The nitpick is perfectly valid... I almost made a note of it. Of course, it would be possible (though silly) to implement an abs function without a comparison, such as sub abs { sqrt($_[0]**2) }.
There's probably some mathematical identity for the abs of the difference of two numbers... but I didn't get enough sleep last night to think about what it might be :-)
In Section
Meditations
|
|