操作系统时间片论转调度算法.docVIP

  • 7
  • 0
  • 约3.03千字
  • 约 6页
  • 2017-08-15 发布于重庆
  • 举报
操作系统时间片论转调度算法.doc

实验报告(一) 1.程序代码: #includestdio.h #includemalloc.h #define N 2 //定义时间片 typedef struct node { char name[10]; int cputime; int needtime; char state; //W for wait,R for run,F for finish struct node *next; }PCB; int n; //进程总数 void show(PCB *pcb,PCB *pcb_rear) //显示某一队列中进程状况 { PCB *p_show; p_show=pcb; while(p_show != pcb_rear) { printf( %s %d %d %c \n,p_show-name,p_show-cputime,p_show-needtime,p_show-state); p_show=p_show-next; } printf( %s %d %d %c \n,p_show-name,p_show-cputime,p_show-needtime,p_

文档评论(0)

1亿VIP精品文档

相关文档