Alex. Gerbessiotis 03/17/2025 SolKeyHW2 332S26 (c) All rights reserved. MARCH 2026. ----------------------------------------------- ----------------------------------- Q1. TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, kernel space, user space, ULT to ULT, Both fork() and wait() Q2. 2.a 7 2.b 3 2.c 3 2.d 1 1st fork 10 / \ / \ 1st fork:10 creates 11 / \ 2nd fork 10 11 / \ / \ 2nd fork:11,10 create 12,13 / \ / \ / \ / \ 3rd fork 10 13 11 12 /\ /\ /\ /\ 3rd fork:12,11,13,10 create 14,15,16,17 / \ / \ / \ / \ 10 17 13 16 11 15 12 14 Q3. (1) Kernel Memory (Space) (2) 4 (3) PCB (4) 44 (5) 22 is the PPID of process 44. Q4. 7,3,7,6,2 Q5. (1) 20, (2) 10003, (c) 40 or 60 (both accepted as correct) In 2 we do not want the PID of the process that run z, but we want the PID of the PARENT of the process that run z. the PID of the process that run z is 10000 the PID of the PARENT of the process that run z is 10003 Q6. a: AAAAABBCDDDDEEE b: CBBDDDDEEEAAAAA d: AAAABBCDDDDAEEE e: 8s f: 7s Info: ABCDE 00005 52143 123456789012345 (a) FCFS: AAAAABBCDDDDEEE (b) SPN : CBBDDDDEEEAAAAA (d) RRq4: AAAABBCDDDDAEEE ReadQ ABBBBCCDAAAAE BCCCCDDAEEEE CDDDDAAE D E (e) Arrival for D t=0s, completion t=12s, s=4s, w=12-0-4=8s (f) Arrival for D t=0s, completion t=11s, s=4s, w=11-0-4=7s Q7. (7.1) (0+9+15)/3=8s (7.2) (9s+9s+6s)/3 = 8s (7.3) 9s (7.4) 0s FCFS AAAAAAAAABBBBBBCCC RR3s AAABBBCCCAAABBBAAA SPN CCCBBBBBBAAAAAAAAA -------------------------------------------------------------- Date created: 03/17/2026 @ 15:02 Date last edited: 03/17/2026 @ 16:30 --------------------------------------------------------------