* threadCount argument: int => std::size_t to avoid implicit casting; * eliminate temporary empty std::thread objects; * replace a trivial lambda with a function pointer and its argument; * get rid of the unused dedicated loop counter.