线程同步

今天要写的小程序是卖票 结果如下:共100张票,10个线程 需要声明的一些变量: public: volatile int m_tickets;//原子访问 static unsigned __stdcall ThreadProc(void* lparam); CListBox m_lstbox; map<unsigned int , int> IDMap;//将线程ID和0~10对应
相关文章
相关标签/搜索