首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
下列程序的输出结果是( )。 struct abc { int a, b, C; ); main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=
下列程序的输出结果是( )。 struct abc { int a, b, C; ); main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=
admin
2010-05-22
32
问题
下列程序的输出结果是( )。 struct abc { int a, b, C; ); main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=S[0].a+S[1].b; printf("%d\n",t); }
选项
A、3
B、4
C、5
D、6
答案
8
解析
street abc s[2]={{1,2,3},{4,5,6}};定义了结构型数组s,数组元素s[0]和s[1]都为结构abc型。因此s[0].a的值为1,s[1].b的值为5,所以t的值为6,选项D正确。
转载请注明原文地址:https://kaotiyun.com/show/5VWp777K
本试题收录于:
二级C语言题库NCRE全国计算机二级分类
0
二级C语言
NCRE全国计算机二级
相关试题推荐
以下变量名中合法的是
下列说法中,错误的是()。
有两个关系R和S如下:由关系R通过运算得到关系S,则所使用的运算为
数据库中对概念模式内容进行说明的语言是()。
某完全二叉树共有256个结点,则该完全二叉树的深度为()。
下列运算符中,优先级别最低的是()。
以下表达式与Int(3.5)的值相同的是
设有工程文件Proj,其中含有Form1窗体、Form2窗体、标准模块Module1.bas,在Form1窗体模块的通用声明段中书写了如下语句PublicXAsInteger,在Form1窗体模块中还定义了通用过程LocalSub。则以下说法中正确的
在文本框控件中,将Text的内容全部显示为用户所定义的字符的属性是()。
设有关键码序列(Q,G,M,Z,A,N,B,P,X,H,Y,S,T,L,K,E),采用堆排序法进行排序,经过初始建堆后关键码值B在序列中的序号是()。
随机试题
被美国社会学家艾尔·巴比称为“社会调查的支柱”的是【】
患者,女,27岁,上前牙牙龈反复出现瘘管1年,经多次搔刮及烧灼瘘管无明显好转。查体见烤瓷全冠修复,唇侧龈可见针尖大小脓点,略红肿,X线片显示根管内冠1/3铸造桩影像,根尖3mm欠充填,根尖区见阴影。引起根尖炎症的优势细菌为
蛋白质变性是由于()。
王某,女,26岁,少量阴道流血7天。今晨起床突然剧烈腹痛伴恶心、呕吐,肛门下坠,头晕。于上午9时急诊入院,查体:BP80/60mmHg,面色苍白,全腹压痛,移动性浊音阳性。妇科检查:宫颈着色、举痛,宫体后位,稍大,软且压痛明显,右侧附件区压痛明显。辅助检查
关于贪污贿赂罪的犯罪主体,下列哪一选项是错误的?
耐火度为2500℃的耐火材料为()。
已经缴人国库的各项预算收人,即成为国家预算资金,它的支配权属于()。
HowtoDoWellinExamsDonotunderestimatethepowerofrevisioninthedaysandhoursbeforeanexamination.Thecloseryoua
______,wirelesscommunicationswillincreasinglybecomepartofthefabricofeverydaylife.
Rabbitearantennasareoldfashionedbutarestillinuse.Theprice$69.95doesn’tincludeS&Hand______foranativeofVi
最新回复
(
0
)