问题 多项选择题

填空题请补充main函数,该函数的功能是:从键盘输入一个长整数,如果这个数是负数,则取它的绝对值,并显示出来。例如,输入:-3847652,结果为:3847652。注意:部分源程序给出如下。请勿改动主函数main和其他函数中的任何内容,仅在函数fun()的横线上填入所编写的若干表达式或语句。试题程序:#include#includemain(){ long int n; clrscr(); printf("Enter the data;\n"); scanf(【1】); printf("*** the absolute value ***\n"); if(n<0) 【2】 printf("\n\n"); printf(【3】);}

答案

参考答案:【A】″%ld″,&n 【B】n=-n; 【C】 ″%ld″, n

解析:填空1:本题考查对标准输入函数scanf()的调用格式,当输入为长整型数时,格式控制字符串为”%ld”,输入的长整数存于变量n中。填空2:当输入的数是负数时,则取它的相反数,即为它的绝对值。填空3:本题考查对标准输出函数printf()的调用格式,当输出为长整型数时,格式控制字符串为”%ld”。

选择题
单项选择题

"This is a really exciting time—a new era is starting," says Peter Bazalgette, the chief creative officer of Endemol, the television company behind "Big Brother" and other popular shows. He is referring to the upsurge of interest in mobile television, a nascent industry at the intersection of telecoms and media which offers new opportunities to device-makers, content producers and mobile- network operators. And he is far from alone in his enthusiasm.

Already, many mobile operators offer a selection of television channels or individual shows, which are " streamed" across their third-generation (3G) networks. In South Korea, television is also sent to mobile phones via satellite and terrestrial broadcast networks, which is far more efficient than sending video across mobile networks; similar broadcasts will begin in Japan in April. In Europe, the Italian arm of 3, a mobile operator, recently acquired Canale 7, a television channel, with a view to launching mobile-TV broadcasts in Italy in the second half of 2006. Similar mobile-TV networks will also be built in Finland and America, and are being tested in many other countries.

Meanwhile, Apple Computer, which launched a video-capable version of its iPod portable music-player in October, is striking deals with television networks to expand the range of shows that can be purchased for viewing on the device, including "Lost", "Desperate Housewives" and "Law & Order". TiVo, maker of the pioneering personal video recorder (PVR), says it plans to enable subscribers to download recorded shows on to iPods and other portable devices for viewing on the move. And mobile TV was one of the big trends at the world’s largest technology fair, the Consumer Electronics Show, which took place in Las Vegas this week.

Despite all this activity, however, the prospects for mobile TV are unclear. For a start, nobody really knows if consumers will pay for it, though surveys suggest they like the idea. Informa, a consultancy, says there will be 125 million mobile-TV users by 2010. But many other mobile technologies inspired high hopes and then failed to live up to expectations. And even if people do want TV on the move, there is further uncertainty in three areas: technology, business models and the content itself.

It can be inferred from the last paragraph of the text that()

A. mobile TV is coming—but how the market will develop is still unclear

B. consumers favor mobile TV if they need not pay for it

C. few mobile technologies failed to live up to expectations

D. the three uncertainties referred to at the end of the text are hopefully overcome in no time