问题 单项选择题

若fp已正确定义并指向某个文件,当未遇到该文件结束标志时函数feof(中)的值为

A.0

B.1

C.-1

D.一个非0值

答案

参考答案:A

解析: 读取文件时,当文件中的数据全部读完后,文件位置指针将位于文件的结尾。此时如果读数据,将会出现错误。为了保证读写数据的正确性,需要进行文件尾测试,文件尾测试使用函数feof(),它的功能测试fp指向的文件是否到达文件尾.若到达文件尾,返回值为非0,否则返回值为0。在本题中fP指向的某文件还没有到了文件尾,因此返回0,所以,4个选项中选项A符合题意。

阅读理解

 

D

One day in early March of 1993, Pauline and Tom Nichter and their 11-year-old son Jason, were shopping for a toy in Buena Park, California. Suddenly, Pauline saw a wallet lying on the floor. When she looked inside, she found $200. The family, homeless and without work, knew that could change their lives. But they took the wallet to the nearby police station and turned it in. The wallet was found to have some other pockets, and more money in — over $2000! The police called the man who lost the wallet to pick it up. The man thanked the Nichters and shook their hands, but did not reward them. Luckily for the family, a TV news re­porter filmed the story. People from all over the world heard the story and sent them letters, money and even jobs. A businessman even let them live in his house for free for six months. So far, the family has received over $1, 000, 000. Now the Nichters’ future is bright.

68. The best title of the reading would be________.

A. Money Is Everything              B. From Have-nots to Haves

C. A Kind Businessman             D. A Lost Wallet and the Police

69. Who found out the “major part of the money” in the wallet?

A. The police.             B. Jason.

C. Someone else in the shop. D. The man who lost the wallet.

70. The words “reward them” in the reading means “_______”.

A. speak highly of the Nichters            B. give something to the Nichters

    C. pay the policemen                  D. meet the news reporters

71. Which of the following is true about the Nichters?

A. They got lots of money from a reporter.

B. They made friends with the loser of the money.

C. They worked for a business for half a year.

D. They became known to many people.

单项选择题