but there is a problem, when i passing them like: ...
# getting-started
g
but there is a problem, when i passing them like:
Copy code
for (i in 1..cores) {
            pool.execute { task(startIndex, endIndex) }
            startIndex = endIndex
            endIndex = if (i < cores - 1) endIndex + length else dataSet.size
        }