
|
4/18: You are required to include the following results/README in this submission. - e1: 1_1_1 (nelev, nppl, seed), 5_20_1. - e2: 1_1_1, 1_5_1, 5_20_1, 5_100_1. - README: Description about how to compile/run your program, and any bug/problem in it. Also address the time spent on each testing. - You source code and Makefile. 4/12: Elevator figure. 4/11: e1/e2 sample outputs: e1: 1 elevator, 2 ppl, seed 1; 1 elevator, 5 ppl, seed 1. e2: 1 elevator, 2ppl , seed 1; 1 elevator, 5 ppl, seed 1. 4/11: When the 5th run finished, is it possible for a person to leave the building if he/she is not at floor 1? Yes. (Then that person might jump out of the windows) If you run the e1/e2 program, you'll find that person can leave the building even if he/she is not at floor 1. 4/11: Is it possible for a person to choose a desired floor which equals to the current floor? The answer is no. If you look into the new_person() in elevator_skeleton.c, you'll see the reason. for (i = 0; i < p->nevents; i++) { p->sleep[i] = random()%15+1; p->floor[i] = (sfloor + 1 + random()%MAXFLOOR)%(MAXFLOOR+1); sfloor = p->floor[i]; } The sfloor is the starting floor (initial value is 1), and p->floor[i] saves the desired floor in each interation. 4/10: Be sure to include a README file in your submission, state how to compile/run the program, and any bugs/problems that might have. 4/10: Due 11:59PM, April 19, 2005. |
|
Frequently Asked Questions: Lab2 |
|
Computer Science 170 |
|
Operating Systems Spring 2005 |
