推 sooge: fork建立成功後 OS會送i=0給child 送i>0的一個數字給parent01/29 18:54
推 sooge: 所以那行else就是parent在做的事01/29 18:58
※ 編輯: lionccc (27.52.101.134), 01/29/2019 19:07:02
推 sooge: 和child無關 不知道有沒有回答到你 你很像把else和else if 01/29 19:07
→ sooge: 以為是二擇一,其實是child和parent各自的程式碼 01/29 19:07
→ lionccc: 嗯嗯我把它搞成2擇1了QQ 這樣我懂了!!謝謝S大 01/29 19:11
推 maple205: 借問,如果題目問創了幾個process 01/29 19:23
→ maple205: 要把main算進去嗎? 01/29 19:24
推 blueskier: 看題目怎麼問,如果單純是問創了幾個就不用算進去 01/29 19:28
推 sdfg014025xx: 選擇題看題目 非選可以自己假設 01/29 19:36
推 imadog: 洪逸好像都會算欸 我記得他都算total 01/29 21:07
→ imadog: 如果問法是how many process are created 要算main嗎? 01/29 21:09
→ rockieloser: 要吧 如果是new才不算? 01/29 21:11
推 Leaving: 交大99OS有一題有算(答案是729的那題) 01/29 21:16