问题 单项选择题

在窗体上添加一个命令按钮,然后编写其单击事件过程为:
For i=1 To 3
x=4
For j=1 To 4
x=3
For k=l To 2
x=x+5
Next k
Next j
Next i
MsgBox x
则单击命令按钮后消息框的输出结果是( )。

A.7

B.8

C.9

D.13

答案

参考答案:D

解析: 本题考查VBA中多重循环的知识。见到多重循环的问题不要害怕,认真地分析清楚每一次循环这种问题就迎刃而解了。比如这个例子,我们看到,在每一次外循环开始的时候都把x的值置为4,所以我们只分析最后一次循环就可以了;同理中层循环每一次开始前都把x置为3,所以这个问题最后实际上就是x的初值为3,执行最内层循环直到结束就可以了。分析程序得知内循环执行两次,所以最后的x=3+5+5=13。

单项选择题
阅读理解

阅读表达。

阅读下面的短文,并根据短文后的要求答题(请注意问题后的字数要求).

     [1]You may be wondering what scientists are like. The aim of this article is to explore the characteristics that are common for scientists. You might even be considering becoming one yourself.

     [2]So now let's get to the topic. What type of person should a scientist be? Don't lose heart if you don't possess(拥有) all of these qualities, but having a few of them will be helpful.

     [3]A scientist should be someone who enjoys research and studying. This makes up a large part of a

scientist's work. Carrying out studies that will improve people's everyday life is an exciting challenge.

Moreover, making the next scientific discovery is highly rewarding but it takes a lot of work and

preparation.

     [4]If you come into contact with a scientist, one of the things you might notice is that they have an open mind. They are flexible and open to new possibilities and there is a very good chance that they might live

their life in this way.

     [5]Perseverance(毅力) is also a quality that is required for a scientist. Experiments don't always go to

plan. Each experiment needs to be adapted slightly to try and encourage more favourable outcomes. A

scientist cannot give up at the first difficulty.

     [6]          , most scientists seem to show curiosity. They seek answers to many mind-puzzling life

questions. Their job is usually to ask how, what and why things happen and to provide theories that

demonstrate this.

1. What is the text mainly about? (no more than 10 words)

                                                                              

2. Complete the following statement with words from Paragraph 2. (no more than 5 words)

It doesn't matter that you don't have all the qualities because having only      is beneficial.

3. How do scientists do their jobs? (no more than 15 words)

                                                                              

4. Please fill in the blank in Paragraph 6 with proper words. (no more than 3 words)

                                                                              

5. What does the word "This" (Line 1, Paragraph 3) probably refers to? (no more than 5 words)