题目内容
【题目】阅读下面的算法语句,输出的结果是( )
I=1
S=0
DO
S=2*S+1
I=I+1
LOOP UNTIL I >4
输出S
A.2 B.10 C.15 D.20
【答案】C
【解析】当I=1时,S=0×2+1=1;当I=2时, S=1×2+1=3;当I=3时,S=3×2+1=7;当I=4时,S=7×2+1=15.故选C.
练习册系列答案
相关题目
【题目】用方框中所给词组的适当形式填空
make no sense all of a sudden make the most of add to |
【1The heavy rain _________our difficulty in completing the project.
【2】 The composition is organized so badly that parts of it _________at all.
【3】The farmers _________the fine weather to harvest the crops before the rainy season comes.
【4】 _________, there came an bomb explosion from outside.