title: OpenMP C and C++ cout/printf does not give the same output
body: <p>I am a complete noob in OpenMP and just started by exploring some simple test script below.</p>
  
  <pre><code>#pragma omp parallel
      {
          #pragma omp for
              for(int i=0;i&lt;10;++i)
              std::cout&lt;&lt;i&lt;&lt;" "&lt;&lt;endl;
           //   printf("%d \n",i);
      }
  }
  </code></pre>
  
  <p>I tried the C and C++ version and the C version seems to work fine whereas the C++ version gives me a wrong output. </p>