Calculate the number of primes in parallel (java, OpenMP, MPI, .NET, MFC, Windows Api)