close
Skip to main content

New answers tagged

Score of 1

Find the average within variable number of doubles

For simplicity, I am writing the following with a standard array double[] a, but porting to ArrayList is straightforward. At the end of the code the desired mean value is always in the variable m. ...
Score of 0

Check whether list of custom objects have same value for a property in Java 8

This is a somewhat verbose solution (unless you're reusing the Gatherer in different places in your code), but in Java 24 or later you could use a custom Gatherer to do this. class State { String ...

Top 50 recent answers are included