未分类题

单击命令按钮时,下列程序代码的运行结果为 Private Sub Command1_Click() Print MyFunc(20, 18) End Sub Public Function MyFunc(m As Integer, n As Integer)As Integer Do While m<>n Do While m>n:m=m-n:Loop Do Whle m<n:n=n-m:Loop Loop MyFunc=m End Function
D.6

A.0
B.2
C.4

【参考答案】

B
解析:本题主要考查对函数的定义和调用的理解。此题程序代码中,被调过程采用了Do While…Loop的嵌套语句结构,主调过程只调用了一次被调过程,Print MyFunc (20,18)语句表明,程序最后输出的只是被调过程的返回值。主调过程在调用被调过程 MyFunc时,把数值20和18...

(↓↓↓ 点击下方‘点击查看答案’看完整答案 ↓↓↓)
热门 试题

未分类题
Health implies. more than physical fitness. It also implies mental and emotional wellbeing. An angry, frustrated, emotionally (1)_____ person in good physical condition is not (2)_____ healthy. Mental health, therefore, has much to do (3)_____ how a person copes with the world as it exists. Many of the factors that (4)_____ physical health also affect mental and emotional well-being.Having a good self-image means that people have positive (5)_____ pictures and good positive feelings about themselves, about what they are capable (6)_____, and about the roles they play. People with good self-images like themselves, and they are (7)_____ like others. Having a good self- image is based (8)_____ a realistic (9)_____ of one's own worth and value and capabilities.Stress is an unavoidable, necessary, and potentially healthful (10)_____ of our society. People of all ages (11)_____ stress. Children begin to (12)_____ stress during prenatal development and during childbirth. Examples of stress-inducing (13)_____ in the life of a young person are death of a pet, pressure to (14)_____ academically, the divorce of parents, or joining a new youth group. The different ways in which individuals (15)_____ to stress may bring healthful or unhealthy results. One person experiencing a great deal of stress may function exceptionally well (16)_____ another may be unable to function at all. If stressful situations are continually encountered, the individual's physical, social, and mental health are eventually affecteD.Satisfying social relations are vital to (17)_____ mental and emotional health. It is believed that in order to (18)_____, develop, and maintain effective and fulfilling social relationships people must (19)_____ the ability to know and trust each other, understand each other, influence, and help each other. They must also be capable of (20)_____ conflicts in a constructive way.A.unstableB.unsureC.impreciseD.impractical
A.B.
C.
D.
A.unstable
B.unsure
C.imprecise
相关试题