27.boost多线程

 1 #define _CRT_SECURE_NO_WARNINGS
 2 #include <boost/thread.hpp>
 3 #include <iostream>
 4 #include <Windows.h>
 5 using namespace std;
 6 using namespace boost;
 7 
 8 
 9 void main()
10 {
11     boost::thread t1([]() {MessageBoxA(0, "1", "1", 0); });
12     boost::thread t2([]() {MessageBoxA(0, "1", "1", 0); });
13     cin.get();
14 }

 

posted @ 2018-04-02 10:55  喵小喵~  阅读(126)  评论(0编辑  收藏  举报