问题 单项选择题

以下关于函数过程的叙述中,正确的是

A.函数过程形参的类型与函数返回值的类型没有关系

B.在函数过程中,过程的返回值可以有多个

C.当数组作为函数过程的参数时,既能以传值方式传递,也能以传址方式传递

D.如果不指明函数过程参数的类型,则该参数没有数据类型

答案

参考答案:A

解析: 函数过程的返回值可以由用户自行定义,不受形式参数的影响。函数过程中,过程的返回值只能有一个,但可以有多种可能。当数组作为函数过程的参数时,一般只能以传地址的方式传输数值。在不指明函数过程参数的类型时,该参数为变体变量(Vriant数据类型),在Visual Basic中参数不可能没有数据类型。

阅读理解

阅读理解。

      An expensive car speeding down the main street of a small town was soon over-taken by a young motorcycle policeman. As he started to take out the ticket, the woman in the car said proudly. "Before you go any further, young man, I think you should know that the mayor of this city is a good friend of mine. "

     The officer did not say a word, but kept writing.

     "I am also a friend of Chief of Police Barnes,"continued the woman, getting angrier each moment.

     Still he kept on writing.

     "Young man," she said, "I know Judge Lawson and State Senator Patton. "

     Handing the ticket to the woman,the officer asked pleasantly. "Tell me, do you know Bill Bronson?"

     "No. Why?" she replied.

     " Well, this is the man you should have known," he said, going back to his motorcycle,"I am Bill Bronson. "

1.The policeman stopped the car because  ___  .

A. it was an expensive car

B. the driver was a proud lady

C. the driver was driving too fast

D. the driver was going to attack him

2. The woman was getting angrier each moment because  __   .

A. the policeman didn't know her friends

B. the policeman kept writing the ticket for her

C. the policeman refused to accept her offer of money

D. she didn't know the policeman's name

3. The woman driving the expensive car  __   .

A. failed to stop the policeman writing the ticket

B. warned the policeman not to move a step further

C. was surprised that the policeman did not know the mayor

D. told the policeman to stay where he was

4. The policeman was   __  .

A. an honest and fair fellow

B. a foolish and proud fellow

C. a silly and rude fellow

D. a kind-hearted fellow

5. The policeman   __ 

A. had no sense of humor

B. had a sense of humor

C. had no sense of duty

D. was playing a joke on the woman

多项选择题 案例分析题