问题
单项选择题
执行下列语句序列: int i=0;while(i<25)i+=3;cout<<i; 输出结果是( )。
A.24
B.25
C.27
D.28
答案
参考答案:C
解析: 本题考查的是循环语句while的使用。i为3的倍数,当i=24时;i<25,执行while的循环体i+=3,则 i=27,不满足i<25的条件,结束循环。
执行下列语句序列: int i=0;while(i<25)i+=3;cout<<i; 输出结果是( )。
A.24
B.25
C.27
D.28
参考答案:C
解析: 本题考查的是循环语句while的使用。i为3的倍数,当i=24时;i<25,执行while的循环体i+=3,则 i=27,不满足i<25的条件,结束循环。
完形填空(共20小题;每小题1. 5分,满分30分) 请阅读下面短文,掌握其大意,然后从下列各题所给的四个选项(A、B、C和D中),选出最佳选项。 Mike has loved flying since he was small. When he was three years old, his father took him to an air show. Mike loved the sounds of the plane, he ___36__ of becoming and airplane pilot(飞行员) someday. As Mike grew up, he learned as ___37___ as he could about flying. He wanted to go to flying school ___38___ university. He kept on ___39___ his parents about it all the time. At that time, pilot training was very ___40___. Mike’s parents couldn’t afford it. Later Mike became a salesman. He hoped to get lots of money for flying school. He traveled ___41___ America for his factory. He liked to travel, ___42___ by plane. To save money, he usually stayed in cheap hotels. One morning, Mike __43___ to Altanta. On the plane, after breakfast, he went to ___44___. Some time later, he woke up. The two men beside him were talking in a ___45___ voice. When Mike heard the word “hijack(劫持)”, he nearly __46___ out of his seat, but he pretended(假装) he was still ___47___ . he listened when the two men talked. Mike quickly learned what was ___48___. They planned to hijack the plane to Cuba. This made Mike very ___49____. He knew he had to stop them before they began their ___50____. Mike pretended to use the washroom. On the way he met a hostess(空姐) and told her about the coming___51____. A moment later, the passengers were told that there was something wrong with the plane. Soon he plane landed at the ___52___ airport. The two men received a __53___ when they saw twenty police officers were ___54___ them at the airport. Later Mike was given free flying training as a reward. __55__ he became a pilot and flew happily ever since. Now his story is well known in the United States.
|