问题 单项选择题

有如下程序:

#include<iostream>

using namespace std;

int main()

void function( double val) ;

double val;

function(val) ;

cout<< val ;

return 0 ;

void function( double val)

val = 3;

编译运行这个程序将出现的情况是( )。

A.编译出错,无法运行

B.输出:3

C.输出:3.0

D.输出一个不确定的数

答案

参考答案:D

解析:

本题考查函数调用及传值方式传递参数,执行函数function时,并没有将3的值传回来,而val又没有初始化,所以会输出一个不确定的值,D选项正确。

判断题
单项选择题

In our society, we must communicate with other people. A great deal of communicating is performed on a person-to-person (1) by the simple means of speech. If we travel in buses, stand in football match (2) , we are likely to have conversations (3) we give information or opinions, and sometimes have our views (4) by other members of society.

Face-to-face contact is (5) the only form of communication, and during the last two hundred years the (6) of mass communication has become one of the dominating factors of contemporary society. Two things, (7) others, have caused the enormous growth of the communication industry. Firstly, inventiveness has (8) advances in printing, photography and so on. Secondly, speed has revolutionized the (9) and reception of communications so that local news often (10) a back seat to national news.

No longer is the possession of information (11) to a privileged minority. Forty years ago people used to (12) to the cinema, but now far more people sit at home and turn on the TV to watch a program that (13) into millions of houses. Communication is no longer merely concerned (14) the transmission of information. The modern communications industry influences the way people live in society and broadens their horizons by allowing (15) to information, education and entertainment. The printing, broadcasting and advertising industries are all (16) with informing, educating and entertaining. (17) a great deal of the material communicated by the mass media is very valuable to the individual and to the society (18) which he is a part, the vast modern network of communications is (19) to abuse. However, the mass media are with us for better, for worse, and there is no turning (20) .

1()

A.basis

B.base

C.level

D.ground