cpp multiple threads code example
Example: multiple threads cpp
#include <iostream>
#include <threads>
#include <vecotr>
std::vector<std::thread*> threads;
for(int i = 0; i < x; i++)
{
threads.push_back(new std::thread(func));
}
#include <iostream>
#include <threads>
#include <vecotr>
std::vector<std::thread*> threads;
for(int i = 0; i < x; i++)
{
threads.push_back(new std::thread(func));
}