GVKun编程网logo

[Linux/C++] 多线程实例:十字路口车辆调度

2

对于[Linux/C++]多线程实例:十字路口车辆调度感兴趣的读者,本文将会是一篇不错的选择,并为您提供关于arch-linux–ArchLinux64bitAndroidADB?、arch-linu

对于[Linux/C++] 多线程实例:十字路口车辆调度感兴趣的读者,本文将会是一篇不错的选择,并为您提供关于arch-linux – Arch Linux 64bit Android ADB?、arch-linux – 在Android设备上启动原生Arch Linux、Bootstrap 创始人 Mark Otto 谈自己生病;替换 RHEL,SUSE 推出 Liberty Linux ; Linux 5.17 使用新调试功能 | 开源日报、C#多线程实例的有用信息。

本文目录一览:

[Linux/C++] 多线程实例:十字路口车辆调度

[Linux/C++] 多线程实例:十字路口车辆调度

实例要求:

有两条道路双向两个车道,即每条路每个方向只有一个车道,两条道路十字交叉。假设车辆只能向前直行,而不允许转弯和后退。如果有4辆车几乎同时到达这个十字路口,如图(a)所示;相互交叉地停下来,如图(b),此时4辆车都将不能继续向前,这是一个典型的死锁问题。从操作系统原理的资源分配观点,如果4辆车都想驶过十字路口,那么对资源的要求如下:

  • 向北行驶的车1需要象限a和b;

  • 向西行驶的车2需要象限b和c;

  • 向南行驶的车3需要象限c和d;

  • 向东行驶的车4需要象限d和a。
    clipboard.png

我们要实现十字路口交通的车辆同步问题,防止汽车在经过十字路口时产生死锁和饥饿。在我们的系统中,东西南北各个方向不断地有车辆经过十字路口(注意:不只有4辆),同一个方向的车辆依次排队通过十字路口。按照交通规则是右边车辆优先通行,如图(a)中,若只有car1、car2、car3,那么车辆通过十字路口的顺序是car3->car2->car1。车辆通行总的规则:
1)来自同一个方向多个车辆到达十字路口时,车辆靠右行驶,依次顺序通过;
2)有多个方向的车辆同时到达十字路口时,按照右边车辆优先通行规则,除非该车在十字路口等待时收到一个立即通行的信号;
3)避免产生死锁;
4)避免产生饥饿;
5)任何一个线程(车辆)不得采用单点调度策略;
6)由于使用AND型信号量机制会使线程(车辆)并发度降低且引起不公平(部分线程饥饿),本题不得使用AND型信号量机制,即在上图中车辆不能要求同时满足两个象限才能顺利通过,如南方车辆不能同时判断a和b是否有空。

我的解决方案(可能存在一些不足,希望大家指出):

/**
 *方法:使用四种线程代表四个方向的车,通过互斥锁和信号量实现题目里的要求。
 */
#include "../lib/myhead.h"
#include <pthread.h>
#include <queue>

#define SLEEP_MS(ms) usleep((ms)*1000) 

using std::queue;
enum Direction{
    NORTH = 1,
    EAST = 2,
    SOUTH = 3,
    WEST = 4
};

/* generate mutex and cond that are required */
template<typename T> struct NormalMutex{
    T val; //store some value that you can use
    bool flag; //control wether using cond
    pthread_mutex_t mutex;
    pthread_cond_t cond;
    NormalMutex():flag(false){
        int err = pthread_mutex_init(&mutex,nullptr);
        if(err!=0) 
            err_exit(err,"mutex init failed");
    }
    /* if you need cond, please set flag true */
    NormalMutex(bool flag):NormalMutex(){
        this->flag = flag;
        if(flag){
            int err = pthread_cond_init(&cond,nullptr);
            if(err!=0)
                err_exit(err,"cond init failed");
        }
    }
    ~NormalMutex(){
        pthread_mutex_destroy(&mutex);
        if(flag)
            pthread_cond_destroy(&cond);
    }
};

/* define the struct containing mutex and cond */
NormalMutex< queue<int> > q_north(true), q_south(true), q_west(true), q_east(true);
NormalMutex<bool> f_north(true), f_south(true), f_west(true), f_east(true);
NormalMutex<int> r_a, r_b, r_c, r_d;

/* define the integer to store the current car in four direction */
NormalMutex<long long> cur_n, cur_s, cur_e, cur_w;

/* define bool to make sure wether a direction has car */
NormalMutex<bool> isin_n, isin_s, isin_e, isin_w;

/* mark the remaining road*/
NormalMutex<int> resource;

/* mark the end of deadlock*/
NormalMutex<bool> dl_over(true);

/* signal four of few val to go firstly */
void init_car(){
    if(q_north.val.size()>0){ //if there are val waiting in the queue, pop one and let it go
        cur_n.val = q_north.val.front(); //pop
        q_north.val.pop();
        pthread_cond_broadcast(&q_north.cond); //let it go
    }
    if(q_south.val.size()>0){
        cur_s.val = q_south.val.front();
        q_south.val.pop();
        pthread_cond_broadcast(&q_south.cond);
    }
    if(q_west.val.size()>0){
        cur_w.val = q_west.val.front();
        q_west.val.pop();
        pthread_cond_broadcast(&q_west.cond);
    }
    if(q_east.val.size()>0){
        cur_e.val = q_east.val.front();
        q_east.val.pop();
        pthread_cond_broadcast(&q_east.cond);
    }
}

int enterTheCrossing(Direction dir,const long long &car_no){
    NormalMutex<int> *road;
    NormalMutex<bool> *isin;
    string direction;
    switch(dir){
        case NORTH:
            road = &r_c; isin = &isin_n; direction = "North"; break;
        case EAST:
            road = &r_b; isin = &isin_e; direction = "East"; break;
        case SOUTH:
              road = &r_a; isin = &isin_s; direction = "South"; break;
        case WEST:
            road = &r_d; isin = &isin_w; direction = "West"; break;
    }
    /* enter the crossing */
    pthread_mutex_lock(&(road->mutex));
    printf("car %lld from %s arrives at crossing\n",car_no,direction.c_str());

    /* things to do after lock the first road */
    isin->val = true; //mark that there is car in north direction
    pthread_mutex_lock(&resource.mutex);
    int tem_re = --resource.val; //let the resource minus one
    pthread_mutex_unlock(&resource.mutex); 

    return tem_re;
}
void detectDeadlock(Direction dir,int tem_re){
    if(tem_re!=0) return ;
    string direction;
    NormalMutex<int> *road;
    NormalMutex<bool> *first, *isin;
    switch(dir){
        case NORTH:
            direction = "East";  road = &r_c;isin = &isin_n; first = &f_east; break;
        case EAST:
            direction = "South"; road = &r_b;isin = &isin_e; first = &f_south; break;
        case SOUTH:
            direction = "West"; road = &r_a;isin = &isin_s; first = &f_west; break;
        case WEST:
            direction = "North"; road = &r_d;isin = &isin_w first = &f_north; break;
    }
    printf("DEADLOCK car jam detected. signal %s to go\n",direction.c_str());
    dl_over.val = false;
    /* deal with the deadlock by making left car go */
    pthread_mutex_unlock(&(road->mutex)); //release the road 
    isin->val = false; //let left car go first
    pthread_cond_signal(&(first->cond));// send the signal to left car

    /* wait the end of deadlock */
    pthread_mutex_lock(&dl_over.mutex);
    while(dl_over.val==false)
        pthread_cond_wait(&dl_over.cond,&dl_over.mutex);
    pthread_mutex_unlock(&dl_over.mutex);

    /* recover from deadlock */   
    pthread_mutex_lock(&(road->mutex)); 
    isin->val = true;
}

void judgeRight(Direction dir){
    NormalMutex<bool> *isin;
    NormalMutex<bool> *first;
    switch(dir){
        case NORTH:
            isin = &isin_w; first = &f_north; break;
        case EAST:
            isin = &isin_n; first = &f_east; break;
        case SOUTH:
            isin = &isin_e; first = &f_south; break;
        case WEST: 
            isin = &isin_s; first = &f_west; break;
    }
    /* juage that if car can go first */
    pthread_mutex_lock(&(first->mutex));
    while(isin->val)
        pthread_cond_wait(&(first->cond),&(first->mutex));
    pthread_mutex_unlock(&(first->mutex));
}

void gotoNextRoad(Direction dir,const long long & car_no){
    string direction;
    NormalMutex<int> *r1,*r2;
    NormalMutex<bool> *isin,*lisin,*first;
    switch(dir){
        case NORTH:
            r1 = &r_c; r2 = &r_d; isin = &isin_n;lisin = &isin_e; first = &f_east; direction = "North";      
            break; 
        case EAST:
            r1 = &r_b; r2 = &r_c; isin = &isin_e;lisin = &isin_s; first = &f_south; direction = "East";
            break;
        case SOUTH:
            r1 = &r_a; r2 = &r_b; isin = &isin_s;lisin = &isin_w; first = &f_west; direction = "South";
            break;
        case WEST:
            r1 = &r_d; r2 = &r_a; isin = &isin_w;lisin = &isin_n; first = &f_north; direction = "West";
            break;
    }
    /* go to next road */
    pthread_mutex_lock(&(r2->mutex));
    /* unlock the first road */    
    pthread_mutex_unlock(&(r1->mutex));
    printf("car %lld from %s leaving crossing\n",car_no,direction.c_str());
    
    /* things to do after unlocking the first road */    
    pthread_mutex_lock(&resource.mutex);
    resource.val++; //resource plus one
    pthread_mutex_unlock(&resource.mutex);
   
       /* out of the deadlock */
    dl_over.val = true;
    pthread_cond_signal(&dl_over.cond);

    /* unlock the second road */
    pthread_mutex_unlock(&(r2->mutex));
   
    isin->val = false; //the road don''t have car
    /* if left direction has waiting car,let it go first*/
    pthread_mutex_lock(&(first->mutex));
    first->val = true; //let left car go first, if exist
    pthread_mutex_unlock(&(first->mutex));
    pthread_cond_signal(&first->cond); //send signal to left car
}
void doAfterGo(Direction dir){
    NormalMutex<queue<int> > *qu;
    NormalMutex<long long> *cur;
    switch(dir){
        case NORTH:
            qu = &q_north; cur = &cur_n; break;
        case EAST:
            qu = &q_east; cur = &cur_e; break;
        case SOUTH:
            qu = &q_south; cur = &cur_s; break;
        case WEST:
            qu = &q_west;  cur = &cur_w; break;
    }

    /* let the next car in the same direction to go */
    pthread_mutex_lock(&(qu->mutex));
    pthread_mutex_lock(&(cur->mutex)); 
    cur->val = qu->val.front(); //set next car to go
    qu->val.pop(); //leave the queue
    pthread_mutex_unlock(&(qu->mutex));
    pthread_mutex_unlock(&(cur->mutex));
    pthread_cond_broadcast(&(qu->cond));     
}

void * n_car(void *arg){
    /* get the car_no from arg*/
    long long car_no = reinterpret_cast<long long>(arg);

    /* block and wait the signal from init_car() or val over it */
    pthread_mutex_lock(&q_north.mutex); 
    while(cur_n.val != car_no){
        pthread_cond_wait(&q_north.cond,&q_north.mutex);
    }
    pthread_mutex_unlock(&q_north.mutex);

    int tem_re = enterTheCrossing(NORTH,car_no);
    detectDeadlock(NORTH,tem_re);
    judgeRight(NORTH);
    gotoNextRoad(NORTH,car_no);
    doAfterGo(NORTH);
    return nullptr;
}
/* the thread representing the car coming from east */
void * e_car(void *arg){
    /* get the car_no from arg*/
    long long car_no = reinterpret_cast<long long>(arg);

    pthread_mutex_lock(&q_east.mutex);
    while(cur_e.val != car_no){
        pthread_cond_wait(&q_east.cond,&q_east.mutex);
    }
    pthread_mutex_unlock(&q_east.mutex);

    int tem_re = enterTheCrossing(EAST,car_no);
    detectDeadlock(EAST,tem_re);
    judgeRight(EAST);
    gotoNextRoad(EAST,car_no);
    doAfterGo(EAST);
    return nullptr;
}

/* the thread representing the car from south */
void * s_car(void *arg){
    /* get the car_no from arg*/
    long long car_no = reinterpret_cast<long long>(arg);

    pthread_mutex_lock(&q_south.mutex);
    while(cur_s.val != car_no){
        pthread_cond_wait(&q_south.cond,&q_south.mutex);
    }
    pthread_mutex_unlock(&q_south.mutex);

    int tem_re = enterTheCrossing(SOUTH,car_no);
    detectDeadlock(SOUTH,tem_re);
    judgeRight(SOUTH);
    gotoNextRoad(SOUTH,car_no);
    doAfterGo(SOUTH);
    return nullptr;
}

/* the thread representing the car from west */
void * w_car(void *arg){
    /* get the car_no from arg*/
    long long car_no = reinterpret_cast<long long>(arg);

    pthread_mutex_lock(&q_west.mutex);
    while(cur_w.val != car_no){
        pthread_cond_wait(&q_west.cond,&q_west.mutex);
    }
    pthread_mutex_unlock(&q_west.mutex);

    int tem_re = enterTheCrossing(WEST,car_no);
    detectDeadlock(WEST,tem_re);
    judgeRight(WEST);
    gotoNextRoad(WEST,car_no);
    doAfterGo(WEST);
    return nullptr;
}
int main(int argc,char *argv[]){
    
    /* check the argv */
    if(argc!=2){
        cout<<"Please input the car stream."<<endl;
        exit(0);
    }

    /* initialize the variable */
    cur_n.val = cur_s.val = cur_e.val = cur_w.val = 0;
    isin_n.val = isin_s.val = isin_e.val = isin_w.val = false;
    resource.val = 4;
    int err = 0;
    int carNumber = strlen(argv[1]);
    pthread_t tids[carNumber+1];
    
    /* create all cars and push them into queue */
    for(int i=1;i<=carNumber;++i){
        switch(argv[1][i-1]){
            case ''n'':
                q_north.val.push(i);
                err = pthread_create(&tids[i],nullptr,n_car,reinterpret_cast<void *>(i));
                if(err!=0)
                    err_exit(err,"can''t create thread");
                break;
            case ''w'':
                q_west.val.push(i);
                err = pthread_create(&tids[i],nullptr,w_car,reinterpret_cast<void *>(i));
                if(err!=0)
                    err_exit(err,"can''t create thread");
                break;
            case ''s'':
                q_south.val.push(i);
                err = pthread_create(&tids[i],nullptr,s_car,reinterpret_cast<void *>(i));
                if(err!=0)
                    err_exit(err,"can''t create thread");
                break;
            case ''e'':
                q_east.val.push(i);
                err = pthread_create(&tids[i],nullptr,e_car,reinterpret_cast<void *>(i));
                if(err!=0)
                    err_exit(err,"can''t create thread");
                break;
        }
    }
    /* wake up the car in front of queue */
    init_car();

    /* join threads */
    for(int i=1;i<=carNumber;++i){
        err = pthread_join(tids[i],nullptr);
        if(err!=0)
            err_exit(err,"can''t join thread %d",i);
    }
    exit(0);
}

代码中使用到的error handler函数:

static void
err_doit(bool, int, const char *, va_list);

void
err_exit(int error, const char *fmt,...){
    va_list ap;
    va_start(ap,fmt);
    err_doit(true,error,fmt,ap);
    va_end(ap);
    exit(1);
}

static void
err_doit(bool errnoflag, int error, const char *fmt, va_list ap){
    char buf[MAXLINE];
    vsnprintf(buf,MAXLINE-1,fmt,ap);
    if(errnoflag)
        snprintf(buf+strlen(buf),MAXLINE-strlen(buf)-1,": %s",strerror(error));
    cerr<<buf<<endl;
}

arch-linux – Arch Linux 64bit Android ADB?

arch-linux – Arch Linux 64bit Android ADB?

我试图在Arch Linux 64bit上使用Android SDK,但是当我尝试从正确的目录运行ADB时,它说文件不存在,但它就在那里.在你遇到这个问题的Ubuntu上安装ia32-lib但是在Arch Linux中没有.有什么我必须做的.

解决方法:

“无此类文件或目录”消息实际上是指32位可执行文件的加载程序,这是执行32位可执行文件所必需的.有关更详细的说明,请参阅Getting “Not found” message when running a 32-bit binary on a 64-bit system.您需要在Arch Linux上安装32位支持.

遗憾的是,Arch Linux没有一种简单的方法来安装32位支持.目前,您需要通过将这些行添加到pacman.conf来启用[multilib]存储库:

[multilib]
Include = /etc/pacman.d/mirrorlist

有关详细信息,请参阅Wiki上的Arch64 FAQ和Using 32-bit-applications on Arch64.

arch-linux – 在Android设备上启动原生Arch Linux

arch-linux – 在Android设备上启动原生Arch Linux

我有一个galaxy Note 10.1(n8010),我想让它本地启动Arch Linux.我的意思是启动Arch Linux而不是android.我需要的只是改变initramfs,这是我在世界上任何地方都找不到的.我的问题:

>我是否只需要更改initramfs,或者我还需要处理其他事情? (比如内核本身)
> [DONE]我在哪里获得CyanogenMod 10.1的官方initramfs(也许是github)?或者我必须自编译CyanogenMod的内核并从zImage中提取它?
> [可能]我可以在Android数据分区中安装Arch linux root吗? (例如/ data / linux)或者我必须购买SD卡?
>我还需要知道/做什么?

编辑:我发现如何更改initramfs

Bootstrap 创始人 Mark Otto 谈自己生病;替换 RHEL,SUSE 推出 Liberty Linux ; Linux 5.17 使用新调试功能 | 开源日报

Bootstrap 创始人 Mark Otto 谈自己生病;替换 RHEL,SUSE 推出 Liberty Linux ; Linux 5.17 使用新调试功能 | 开源日报

开源吞噬世界的趋势下,借助开源软件,基于开源协议,任何人都可以得到项目的源代码,加以学习、修改,甚至是重新分发。关注「开源日报」,一文速览国内外开源大事件吧!

一分钟速览新闻点!

  • SUSE 为怀念旧 CentOS 的开发者们发布新发行版——Liberty Linux
  • Bootstrap 创始人 Mark otto 谈及自己生病
  • 欧盟委员会开源计划办公室启动漏洞赏金
  • Google 在 Windows 上发布 beta 版本的 Google Play Games app
  • Linux 5.17 使用新的调试功能,便于开发者更能轻松构建内核
  • 基于 Chromium 项目的微软 Edge 浏览器大变更
  • JetBrains 提供面向开发人员的免费开源字体 Mono

开源大新闻

SUSE 为怀念旧 CentOS 的开发者们发布新发行版——Liberty Linux

自从 2020 年红帽宣布终止 CentOS Linux 的支持,并用 CentOS Stream 取而代之后,RHEL 的替代品便相继涌现。知名 Linux 发行套件供应商 SUSE 带来了全新的 SUSE Liberty Linux 产品。据官方介绍,借助 SUSE Liberty Linux,用户可以通过经过验证的可选管理工具获得值得信赖的支持,这些工具针对混合 Linux 环境进行了优化,包括 Red Hat Enterprise Linux 、CentOS 以及用户所期望的 openSUSE 和 SUSE Linux Enterprise Server。而在一定程度上来看,Liberty Linux 等同于当前的 Red Hat 版本——RHEL 8.5 ,并且与来自 Red Hat 自己的 EPEL 存储库的软件包兼容。

Bootstrap 创始人 Mark otto 谈及自己生病

1 月 20 日,Bootstrap 创始人 Mark otto 发文表示,“2021 年 12 月 5 日,我的心脏病发作,在医院住了两个星期。第一周,我在重症监护室里处于医学上的昏迷状态,以冷冻的方式保存我身心。没有人知道当我醒来时,我是否还是我。”

幸运的是,一周之后,Mark otto 苏醒过来,分享道“好消息是我的心脏有一个新支架,而且我恢复得很好。我一直在慢慢地重新使用 Bootstrap 以确保我仍然可以设计和编码(我可以!),现在我会在网上逗留一段时间后下班休息。”同时,他也希望通过此事能够让更多的人关注自己的健康,“多和你的医生交谈、做更多的检查、了解遗传病史、锻炼身体,尽可能地保持安全和健康。虽然这有些陈词滥调,但它可以很好地挽救你的生命。”

Bootstrap是一个基于 HTML、CSS、JavaScript 的简洁灵活的网站前端框架及组件包,它也是 GitHub 上面 star 次数排名第十二的项目。Star 次数超过 155,000。

在这里插入图片描述

欧盟委员会开源计划办公室启动漏洞赏金

欧盟委员会开源计划办公室(EC OSPO)的一组新的漏洞赏金于 1 月 13 日启动,使用 Intigriti 漏洞赏金平台。其中,欧盟委员会开源计划办公室(EC OSPO)总共资助了200,000 欧元,用于再次关注公共服务广泛使用的开源软件的安全性。如在 LibreOffice、LEOS、Mastodon、odoo 和 CryptPad(欧盟公共服务部门使用的开源解决方案)中发现安全漏洞的奖励最高可达 5000 欧元。为他们发现的错误提供代码修复有 20% 的奖金。

Google 在 Windows 上发布 beta 版本的 Google Play Games app

Google 上个月透露要将 Android 游戏带到所有 Windows 平台。现在它正式释出了 beta 版本的 Google Play Games app,目前只对部分地区开放测试。Google 称,Google Play Games app 允许用户在 Windows 台式机或笔记本电脑上浏览、下载和玩部分手游,支持使用键盘和鼠标、在设备之间无缝同步以及与 Google Play Points 集成。该应用暂不支持 Mac。系统要求 Windows 10(v2004),8GB 内存,固态硬盘,20 GB 储存空间,8 核处理器,游戏类显卡(目前市场上的中低端显卡都支持),启用硬件虚拟化。

开源软件专区

Linux 5.17 使用新的调试功能,便于开发者更能轻松构建内核

多年来,Linux 内核支持多种 sanitizers、内存泄漏检测器等功能,这些功能主要用于帮助诊断和解决内核中的缺陷。然而,所有这些调试优化的功能并没有集中在一起,这使系统管理员和开发者在手动配置内核构建时,难以发现这些众多的功能。现在,随着 Linux 5.17 的推出,这种情况正在改变。

Linux 5.17 所做的是引入 debug.config 作为默认的内核构建配置,为调试进行优化。debug.config 将默认启用各种功能,如内核地址消毒器、未定义行为消毒器、KMemLeak,以及许多其他随着时间推移而增加的内核功能,旨在帮助调试或追踪内核问题。因此,只要一个命令,就可以得到官方推荐的内核配置,并启用许多不同的调试功能。

基于 Chromium 项目的微软 Edge 浏览器大变更

近日,微软宣布,从 Edge 96 版本开始,Web 应用将能够在浏览器中使用协议处理程序。最新功能将允许已安装的 Web 应用程序(或 PWA)导航预设或自定义协议。已安装的 Web 应用程序也将能够向操作系统注册为协议处理程序,并在调用特定协议后启动。换句话说,用户可以将网页设置为默认处理程序,比如用户想创建电子邮件,系统将默认打开浏览器中的某个网站。

此外,开发者可以通过注册以 web+ 为前缀的协议来生成 Web 应用程序自定义方案。协议处理程序可用于 Web 应用通信,其中一个应用直接调用另一个应用并通过自定义协议链接传递数据。(小编)

开源工具推荐

JetBrains 提供面向开发人员的免费开源字体 Mono

JetBrains 于近日开源 Mono 字体,其可以作为独立下载提供,并且还被捆绑在所有JetBrains IDE 中。JetBrains Mono 的默认版本带有 OpenType 功能和连字(始终可以在设置中打开和关闭)。如果有开发者的 IDE 不支持 OpenType,也可以使用该字体的特殊版本 — JetBrains Mono NL,其中不包含任何连字。

在这里插入图片描述


《新程序员003》正式上市,50 余位技术专家共同创作,云原生和数字化的开发者们的一本技术精选图书。内容既有发展趋势及方法论结构,华为、阿里、字节跳动、网易、快手、微软、亚马逊、英特尔、西门子、施耐德等 30 多家知名公司云原生和数字化一手实战经验!

订阅地址:https://mall.csdn.net/item/92470?utm_source=csdn_news_group

在这里插入图片描述

总结

以上是小编为你收集整理的Bootstrap 创始人 Mark Otto 谈自己生病;替换 RHEL,SUSE 推出 Liberty Linux ; Linux 5.17 使用新调试功能 | 开源日报全部内容。

如果觉得小编网站内容还不错,欢迎将小编网站推荐给好友。

原文地址:https://blog.csdn.net/csdnopensource/article/details/122615511

C#多线程实例

C#多线程实例

如果需要查看更多文章,请微信搜索公众号 csharp编程大全,需要进C#交流群群请加微信z438679770,备注进群, 我邀请你进群! ! !

 

 

 

using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Threading.Tasks;using System.Windows.Forms;using System.Threading;namespace 线程实例1{ public partial class Form1 : Form {  public Form1()  {   InitializeComponent();  }  private void Form1_Load(obj.........

关于[Linux/C++] 多线程实例:十字路口车辆调度的问题我们已经讲解完毕,感谢您的阅读,如果还想了解更多关于arch-linux – Arch Linux 64bit Android ADB?、arch-linux – 在Android设备上启动原生Arch Linux、Bootstrap 创始人 Mark Otto 谈自己生病;替换 RHEL,SUSE 推出 Liberty Linux ; Linux 5.17 使用新调试功能 | 开源日报、C#多线程实例等相关内容,可以在本站寻找。

本文标签: