我想請教下大家以下幾題問題
圖片參考:http://i225.photobucket.com/albums/dd54/icon_2kf/00017.gif
第一題:
What is the output of the following pseudocode?
10 x=12
20 y=15
30 y=y-x
40 x=x-y
50 IF x/3>y THEN Output y
60 ELSE Output x
70 ENDIF
咁個output係點出,列清步驟唔該
第二題:
How many times will instruction line 31 be executed?
11 P=18
21 DO
31 P=P-3
41 WHILE P<=6
咁呢題又點搵
圖片參考:http://i225.photobucket.com/albums/dd54/icon_2kf/00019.gif
第三題:
How many times will instruction line 30 be executed?
10 P=18
20 REPEAT
30 P=P-3
40 UNTIL P<=6
呢個又點計
圖片參考:http://i225.photobucket.com/albums/dd54/icon_2kf/00019.gif
詳細小小唔該,急要
圖片參考:http://i225.photobucket.com/albums/dd54/icon_2kf/00020.gif
希望大家幫下手啦
圖片參考:http://i225.photobucket.com/albums/dd54/icon_2kf/00015.gif