Multithread to print odd and even numbers
Multiple threads are usually used to compute things in parallel.
In this example nothing is computed in parallel:
while one thread is running,
the other is waiting.
With no practical value,
it's not a great demonstration of multithreading.
I suggest to look for more practical targets in the future.

Since evenready and oddready always have opposite values,
one of them would be enough, and less error-prone.

Instead of for (; x &lt; 10;) { it's more natural to use while (x &lt; 10) {.

using namespace std; is considered bad practice.