반응형
.
#include <iostream>
#include <thread>
void hello() {
std::cout << "Hello Concurrent World\n";
}
int main() {
std::thread t(hello);
t.join();
}
.
$ g++ -pthread test.cpp
반응형
.
#include <iostream>
#include <thread>
void hello() {
std::cout << "Hello Concurrent World\n";
}
int main() {
std::thread t(hello);
t.join();
}
.
$ g++ -pthread test.cpp
댓글