首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
阅读下面语句,则程序的执行结果是【 】。 #include "stdio.h" main() { int a=-1,b=1,k; if((++a
阅读下面语句,则程序的执行结果是【 】。 #include "stdio.h" main() { int a=-1,b=1,k; if((++a
admin
2010-12-10
29
问题
阅读下面语句,则程序的执行结果是【 】。
#include "stdio.h"
main()
{ int a=-1,b=1,k;
if((++a<0)&&!(b--<=0))
printf("%d,%d\",a,b);
else printf("%d,%d\n",b,a);}
选项
答案
1,0
解析
与运算两边的语句必须同时为真时,结果才为真。当执行完if((++a<0)&&!(b--<=0))时,a,b的值已经发生了变化。
转载请注明原文地址:https://kaotiyun.com/show/hTPp777K
本试题收录于:
二级C语言题库NCRE全国计算机二级分类
0
二级C语言
NCRE全国计算机二级
相关试题推荐
在考生文件夹中有一个工程文件sjt5.vbp。该程序的功能是:分别统计7×7数组四周元素之和及四周元素中能够被7整除的元素的个数,并将统计结果在相应的标签中显示。请仔细阅读已有程序,然后在标出的位置编写适当的程序,以实现上述的功能。要求:不得修改
如果把程序的启动对象设置为:SubMain,则SubMain过程
设有如下一段程序:PrivateSubCommand1_Click() StaticaAsVariant a=Array("one","two","three","four","five") Printa(3)EndS
下面哪个属性肯定不是框架控件的属性( )。
三角形的构成条件是:任意2边之和大于第3边。设变量a、b、c是3条直线的长度,要求判断这3条直线能否构成一个三角形。下面有3个程序段可以正确判断,另一个不能正确判断的是
下列有关控件的叙述中,正确的是
在关系数据库中,用来表示实体间联系的是
现有如下语句:x=lIf(a>50,Int(a\3),aMod2)当a=52时,x的值是()。
数据流图用于抽象描述一个软件的逻辑模型,数据流图由一些特定的图符构成。下列图符名标识的图符不属于数据流图合法图符的是()。
随机试题
具有温肺止咳功效的药物是
物价持续上涨,存货发出采用先进先出法时月末存货的价值,将大于采用后进先出法时月末存货的价值。()
商用房贷款利率不得低于中国人民银行规定的同期同档次的1倍。()
丙公司生产和销售E、F两种产品,每年产销平衡。为了加强产品成本管理,合理确定下年度经营计划和产品销售价格,该公司专门召开总经理办公会进行讨论。相关资料如下:资料一:2019年E产品实际产销量为3680件,生产实际用工为7000小时,实际人工成本为16元/
某股票的未来股利不变,当股票市价低于股票价值时,则股票的投资收益率比投资人要求的最低报酬率低。()
三心:两意与()在内在逻辑关系上最为相似。
Whattimeisitnow?
Ifxandyareintegersandxy3isapositiveoddinteger,whichofthefollowingmustbetrue?
Youshouldspendabout40minutesonthistask.Writeaboutthefollowingtopic:Beingacelebrity-suchasafamousfilmstar
Thetendencynowadaystowanderinwildernessesisdelightfultosee.Thousandsoftired,nerve-shaking,over-civilizedpeoplea
最新回复
(
0
)