Elegant min/max absolute values in java
- by Stefano Borini
I need to get the minimum and maximum values in a collection of floating point values, after applying an absolute value conversion. In python I would do this
min(map(abs, [-5, -7, 10, 2]))
how can I perform the same operation in java in the most elegant way?