问题 填空题

若有以下程序段:
int c1=1,c2=2,c3;
c3=1.0/c2*c1;
则执行后,c3中的值是 【9】

答案

参考答案:0

解析: 在赋值运算中。如果表达式中变量和常量的数据类型不一致就会自动进行类型转换。系统会计算 1.0/c2,由于1.0是实型,所以均先转化为双精度型0. 500000,再和c1转化后的双精度数相乘得0.500000。但其要赋值给整型变量c3,故要进行强制转换,c3的值为0。

解答题
完形填空
完形填空。
     What is intelligence (智力) anyway? When I was in the army I  1   an intelligence test that all soldiers
took, and, against  2    of 100, I scored 160.
     I had an auto-repair man once, who, on these intelligence tests, could not   3   have scored more than
80.  4  , when anything went wrong with my car I hurried to him-and he always  5   it.
      Well, then, suppose my auto-repair man  6  questions for some intelligence tests. By every one of
them I'd prove myself a  7  . In a world where I have to work with my  8  , I'd do poorly.
     Consider my auto-repair man  9  . He had a habit of telling   10   .One time he said, "Doc, a deaf-and-dumb (聋哑) man   11   some nails. Having entered a store, he put two fingers together on the counter
and made  12   movements with the other hand. The clerk brought him a hammer. He 13  his head and
pointed to the two fingers he was hammering. The clerk  14  him some nails. He picked out the right size
 and left. Well, Doc, the 15  man who came in was blind. He wanted scissors (剪刀).  16  do you
suppose he asked for them?" I lifted my right hand and made scissoring movements with my first two
fingers. He burst out laughing and said, "Why, you fool,he used his 17  and asked for them. I've been
 18   that on all my customers today,but I knew  19   I'd catch you." "Why is that?" I asked. "Because
you are so goddamned educated. Doc. I knew you couldn't be very  20  ".
And I have an uneasy feeling he had something there.
( )1. A. failed
( )2. A. an average
( )3. A. always
( )4. A. Then   
( )5. A. fixed
( )6. A. answered  
( )7. A. teacher
( )8. A. brains
( )9. A. again
( )10. A. lies
( )11. A. bought
( )12. A. cutting
( )13. A. nodded
( )14. A. brought
( )15. A. clever
( )16. A. What
( )17. A. imagination
( )18. A. trying
( )19. A. for sure
( )20. A. clear
B. wrote
B. a total
B. possibly
B. Thus   
B. checked
B. practised
B. doctor
B. effort
B. as usual
B. jokes
B. tested
B. hammering
B. raised
B. packed
B. other
B. How   
B. hand   
B. proving
B. at once
B. silly
C. received
C. an exam
C. certainly
C. Therefore
C. drove
C. designed
C. winner
C. hands
C. too
C. news
C. found
C. waving
C. shook
C. sent
C. right
C. Who   
C. voice
C. practising
C. in fact
C. slow
D. chose          
D. a number        
D. frequently      
D. Yet            
D. changed        
D. tried          
D. fool            
D. attention      
D. as well        
D. tales          
D. needed          
D. circling        
D. turned          
D. sold            
D. next            
D. Which          
D. information    
D. examining      
D. right now      
D. smart