Parallel functions and sorting

Sorry for the somewhat trivial question… but for parallel functions (.each() .some() …), is the resulting sorting guaranteed to be correct?

Or do I have to worry about my software guaranteeing it?

I’ve done some testing on large datasets, and the sorting is always correct, but I’d like to be sure.

Thanks!

1 Like

I think there’s no explicit underlying guarantee when using parallel=true, whenever a closure finishes it returns it’s result?

sorting is pretty simple, you can easily test by putting a random sleep amount in the closure

1 Like