问题 填空题

以下程序的输出结果是【 】。  #include<iostream.h>  unsignedfun(unsignednum)  { unsignedk=1;    do { k * =num%10;num/=10;}while(num);    returnk;  }  voidmain( )  { unsignedn=26;    cout<<fun(n)<<endl;  =

答案

参考答案:L

解析:函数有一个形参num,循环前变量k置1,循环中,表达式num%10是取num 的个位,将num的个位值累乘于k中,然后num除以10。循环直至num为。结束,这是 逐一求出num十进制表示的各位数字,并累乘于变量k的循环。函数最后返回k。函数 fun的功能是求整数的各位十进数字积。

完形填空
完形填空。
     Perhaps you ride a bicycle to school. Riding a bicycle can be great fun. Do you know how to ride
a bicycle  1 ?
    Careful boys and girls learn to ride their bicycle well  2  they go out on the road. How can you
tell  3  you are a good rider?
     If you can ride a bicycle in a straight line, you can ride well. If you can't ,you should practise riding 
 4  a safe place. To be safe on a bicycle, you  5  to use both hands and both feet.  6  your
feet on the pedals and your hands on the handle bars at all times.
    Do you have a basket on your bicycle? If so, put your books and packages in it. Then you can
 7  both hands on the handle bars.
     You know that your bicycle is built for one person. It is not safe to carry anyone  8 you.   9  is this
so? Keep  10  safe by safety rules when you ride on a bicycle. Watch where you are going at all times.
( )1. A. safe      
( )2. A. as soon as
( )3. A. that   
( )4. A. in      
( )5. A. must      
( )6. A. Keep      
( )7. A. keep      
( )8. A. to       
( )9. A. Where    
( )10. A. it     
B. safety
B. before
B. how  
B. on    
B. need  
B. Make  
B. make  
B. for    
B. Why    
B. yours  
C. safely  
C. after  
C. what    
C. at      
C. may    
C. Let    
C. let    
C. with    
C. What    
C. you    
D. save    
D. until    
D. whether  
D. to      
D. can      
D. Get      
D. get      
D. by                                 
D. How      
D. yourself
多项选择题