问题 填空题

执行以下程序段后,变量c$的值是 【7】
a$="北京"
b$="Shanghai"
c$="Left(a$,2)+String(3,"—")+Right(b$,8)

答案

参考答案:北京——Shanghai

解析: 本题主是考查了Left、String和 Right三个字符串函数。Left(C,N)函数表示从字符串C的左边取出N个字符。Right(C, N)函数表示从字符串C的右边取出N个字符。String(N,C)函数返回N个指定字符构成的字符串。题中Left(a$,2)的值为“北京”, String(3,"—")的值为“———”,Right(b$, 8)的值为"Shanghai"。然后用运算符“+”将三个字符串连接成一个字符串得:北京—— Shanghai。

完形填空
完形填空。
      Billy is a boy of fifteen. His parents died three years ago. One day when he was walking in the street, he
   1   a wallet. He returned it to the owner, Mr Baker. He gave his   2   to the boy. As the boy had no job, Mr
Baker made him work for him in his   3  . Billy worked so hard that Mr and Mrs Baker were   4   with him.
     Mr Baker loved planting   5  . The week before last, he brought a few trees home, planted them in the   6   
himself and watered them every day. Several days   7  , he had to leave for another city. Before he started, he
said to Billy,"Take good care of these trees. Some boys near our house always want to steal them.""Don't   8   
about them, sir."answered Billy,"I'll try my best to watch them."Six days passed and Mr Baker came back. He
asked," 
  9   anyone ever come to steal the trees?" "No, sir."said Billy. "To stop someone from stealing the trees, I   10 
 them up six days ago. I have hidden them for almost a week!"
( )1. A. bought  
( )2. A. wallet  
( )3. A. office  
( )4. A. pleased 
( )5. A. grass   
( )6. A. garden  
( )7. A. ago     
( )8. A. think   
( )9. A. Did     
( )10. A. sent   
B. found       
B. pity        
B. factory    
B. angry        
B. flowers  
B. office   
B. later         
B. talk     
B. Does           
B. pulled 
C. carried            
C. thanks                
C. town               
C. bored                   
C. vegetables      
C. city              
C. before              
C. learn          
C. Has                       
C. put        
D. wanted           
D. excuses              
D. home               
D. sad                      
D. trees          
D. room             
D. after                
D. worry            
D. Will               
D. picked         
单项选择题