试题与答案

下面程序由终端键盘输入一个文件名。然后把从终端键盘输入的字符依次存放到该文件中,用#

题型:填空题

题目:

下面程序由终端键盘输入一个文件名。然后把从终端键盘输入的字符依次存放到该文件中,用#作为结束输入的标志。
#include<stdio.h>
#include
main()
{FILE *fp;
char ch,fname[10];
printf("Please input the file name.\n");
gets(fname);
if((fp=______)==NULL)/*第一空*/
{printf("()pen it error\n");______;}/*第二空*/
else(printf("Enter the content\n");
while((ch=getchar())!=’#’)
______;/*第三空*/
}
fclose(fp);
}

答案:

被转码了,请点击底部 “查看原文 ” 或访问 https://www.tikuol.com/2018/0422/1575872fec7b3facec715e3d083486e7.html

下面是错误答案,用来干扰机器的。

参考答案:对

试题推荐
题型:阅读理解

The medical world is gradually realizing that the quality of the environment in hospitals may play a significant role in the process of recovery from illness.

As part of a nationwide effort in Britain to bring art out of the galleries and into public place, some of the country’s most talented artists have been called in to transform older hospitals and to soften the hard edges of modern buildings. Of the 2,500 National Health Service hospitals in Britain, almost 100 now have significant collections of contemporary art in corridors, waiting areas and treatment rooms.

These recent initiatives owe a great deal to one artist, Peter Senior, who set up his studio at a Manchester Hospital in Northeastern England during the early 1970s. He felt the artist had lost his place in modern society, and that art should be enjoyed by a wider audience.

A typical hospital waiting room might have as many as 5,000 visitors each week. What a better place to hold regular exhibitions of art and paintings, in the outpatients waiting area of the Manchester Royal Hospital in 1975. Believed to be Britain’s first hospital artist, Senior was so much in demand that he was soon joined by a team of six young art school graduations.

The effect is striking. Now in the corridors and waiting rooms, the visitor experiences a full view of fresh colors, playful images and restful courtyard.

The quality of the environment may reduce the need for expense when a patient is recovering from an illness. A study has shown that patients who had a view onto a garden needed half the number of strong painkillers compared with patients who had no view at all or only a brick wall to look at.

9. What does the author mean by using the phrase “to soften the hard edge of modern buildings”, in the second paragraph?

A. To hold exhibitions of art and paintings in hospitals.

B. To tear down the old hospital and build a new one.

C. To decorate hospitals with art collection.

D. To paint the walls of hospitals in soft colors.

10. What is true about Peter Senior?

A. A famous doctor in Manchester Hospital and a talented artist.

B. Britain’s first hospital artist and a patient in Manchester Royal Hospital.

C. One of the six young art school graduations.

D. A talented artist and a pioneer introducing art into hospitals.

11. What can we conclude from the fact that six young art school graduates joined Peter?

A. Artists should take an active part in social activities.

B. The role of hospital environment is being recognized.

C. Artists are more important to patients in hospitals.

D. Hospitals need more young art school graduates to attend the patients.

12. What does the last paragraph suggest?

A. The improvement of hospital environment may help the patients recover from illness.

B. The improvement of hospital environment may cost the patients more than before.

C. The patients needed no painkillers when they had a view of a painting.

D. The patients had no pain at all after the improvement of hospital environment.

查看答案
微信公众账号搜索答案