• ###### boringMaxcommented on "Boolean Postfix" java solution

Ouch, that hurts

Typical.

pak

• ###### dmpronicommented on "Santa's Naughty List" java solution

Very good remark, but everything is not so easy and depends entirely on data.
You can test it yourself, just imagine the list with 10 distinct values, each repeated 1000 times. It's much more easy to 'hashset' it in the start, then sort 10 values, then sorted 10000 values, and only then take only unique ones.
So, one more time, it depends on the data.

• ###### Murzogcommented on "Geometry Basics: Distance between points in 2D" python solution

you should see what sagemath can do. I strongly recommend using sagemath as it is python 3 with a huge library of extra modules specifically for applied and abstract mathematics.

• ###### Elakiouicommented on "Odd or Even?" java solution

I think Arrays.stream() accepts array of objects no primitive array. isn't it ?

• ###### bouchertcommented on "Keep Hydrated!" python solution

In Python 3, the result of the `/` operator (known as `truediv`) is a float, but the result of `//` (known as `floordiv`) is already an int and rounding it will have no effect.

• ###### SantiSanchez88commented on "Keep Hydrated!" python solution

I used the same code but to avoid floats I just,

round(time//2)

• ###### ӜЯℱӁℒᚹcommented on "How good are you really?" java solution

That's a catch for the case of null values. (incase when `.isPresent()` returns false)

• ###### hogwartsdevelopercommented on "How good are you really?" java solution

orElse(0) which means?

Wow

• ###### heppletoncommented on "Geometry Basics: Distance between points in 2D" python solution

Don't know why I didn't expect math to have a hypotenuse function. Should read the documentation.

• ###### houstcommented on "Range Extraction" java solution

Please, try to avoid loop inside loop if possible and in this task it is possible^)