Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 1

Câu 13: Khi chạy đoạn chương trình trên, khi chạy hết sẽ có 16 tiến trình được

sinh ra. Theo đoạn code trên thì khi chạy, tiến trình được tạo ra từ chương trình
sẽ in ra màn hình 16 dòng “hello”. Cây tiến trình khi thực thi đoạn chương trình
trên như sau:
P0
P0 P1
“hello” “hello”
P0 P2 P1 P3
“hello” “hello” “hello” “hello”
P0 P4 P2 P5 P1 P6 P3 P7
“hello” “hello” “hello” “hello” “hello” “hello” “hello” “hello”
P0 P8 P4 P9 P2 P10 P5 P11 P1 P12 P6 P13 P3 P14 P7 P15
“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”“hello”

You might also like