freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內容

[it認證]計算機二級c語言歷年真題-在線瀏覽

2025-03-03 22:52本頁面
  

【正文】 ) char s[7] 。C) char *s 。 D) char s[7] 。(24)以下關于return語句的敘述中正確的是DA)一個自定義函數中必須有一條return語句B) 一個自定義函數中可以根據不同情況設置多條return語句C)定義成viod類型的函數中可以有帶返回值的return語句D)沒有return語句的自定義函數在執(zhí)行結束時不能返回到調用處(25)下列選項中,能夠正確定義數組的語句是DA)int num[0..2008]。C) int N=2008。 int num[N](26)有以下程序includevoid fun (char*c,int d){*c=*c+1。printf(”%c,%c,”,*c,d)。 fun(amp。 printf(”%c,%c\n”,b,a)。,則下列說法正確的是DA)定義了基類型為int的三個指針變量B)定義了基類型為int的具有三個元素的指針數組pt。,一下能夠代表數組元素a[3]的是BA)(*s)[3] B)*(s+3) C)*s[3] D)*s+3(29)有以下程序includemain(){ int a[5]={1,2,3,4,5}, b[5]={0,2,1,3,0},is=0 for(i=0。i++) s=s+a[b[i]]。}程序運行后的輸出結果是CA) 6 B) 10 C) 11 D)1530)有以下程序 include main(){ int b[3] [3]={0,1,2,0,1,2,0,1,2},i,j,t=1。 i3。j=i。Printf(%d\n,t)。 printf(%d %d\n, strlen(s1),strlen(s2))。}main(){ int a[N]={1,2,3,4,5,6,7,8},i。for(i=0。 i++){ printf(%d,a[i])。}程序運行后的輸出結果是CA)1 3 1 3 B) 2 2 3 4 C) 3 2 3 4 D)1 2 3 4 (33)有以下程序includeint f(int t [ ],int n)。s=f{a,4}。}int f(int t[], int n){ if (n0) return t[n1]+f(t,n1)。}程序運行后的輸出結果是BA)4 B)10 C)14 D)6(34)有以下程序includeint fun(){static int x=1。 return x。for (i=1。i++) s=fun()。}程序運行后的輸出結果是CA)0 B)1 C) 4 D)8(35)以下程序include define SUB(a) (a)(a)main(){int a=2,b=3,c=5,d。printf(”%d\n”,d)。} datal={1,8},data2。 B)data2=(2,6)。 D)=。 char b[10]。}。main(){struct A a={1001,”ZhangDa”,}。 pringt(”%d,%s,%\n”,)。strcpy(,”ChangRong”)。}程序運行后的輸出結果是AA)1001,ZhangDa, B)1002,ChangRong,C)1001,ChangRong, D)1002,ZhangDa,(38)有以下定義和語句struct workers{int num。char c。int month。} s。struct workers w,*pw。w能給w中year成員賦1980的語句是DA)*=1980。C)pwyear=1980。 (39)有以下程序include main(){int a=2,b=2,c=2。c)。char str[10]。fputs(”abc”,fp)。fp=fopen(””,”a+”)。rewind(fp)。 puts(str)。 }程序運行后的輸出結果是CA)abc B)28c C)abc28 D)因類型不一致而出錯二、填空題(每空2分,共30分)請將每空的正確答案寫在答題卡【1】至【15】序號的橫線上,答在試卷上不得分。(2)設某循環(huán)列隊的容量為50,如果頭指針front=45(指向隊頭元素的前一位置),尾指針rear=10(指向隊尾元素),則該循環(huán)隊列中共有___15__個元素。(5)有一個學生選課的關系,其中學生的關系模式為:學生(學號,姓名,班級,年齡),課程的關系模式為:課程(課號,課程名,學時),其中兩個關系模式的鍵分別是學好和課號,則關系模式選課可以定義為:選課(學號, 課號 ,成績)。amp。(7)有以下程序include main(){ int a=1,b=2,c=3,d=0。 else d=2。 else d=4。 printf(”%d\n”,d)。(8)有以下程序include main(){ int m,n。m,amp。while (m!=n){ while(mn) m=mn。}printf(”%d\n”,m)。i3。j3。 printf(”\n”)。 while(i3) { k[i]=amp。 printf(”%d”,*k[i])。 }}程序運行后的輸出結果是____135______(11) 有以下程序 include main(){ int a[3][3]={{1,2,3},{4,5,6},{7,8,9}}。 for(i=0。i++) b[i]=a[i][2]+a[2][i]。i3。 printf(”\n”)。 int n,i。 temp=str[n1]。i0。 str[0]=temp。 scanf(”%s”,s)。 printf(”%s\n”,s)。請?zhí)羁铡? printf(”%d%d%d\n”, X%10 ,x/10%10,x/100)。includemain(){ char s[100]={”our .tercher teach c language!”};int i,j。s[i]!=‘\0’。j++。printf(”%s\n”,s)。請?zhí)羁铡?for(p=a。p++) scanf(”%d”,p)。pa10。 printf(”index=%d\n”,sa)。amp。 float printF。 scanf(“%d %f”,amp。pjrintF)。 } 該程序編譯時產生錯誤,其出錯原因是 A)定義語句出錯,case是關鍵字,不能用作用戶自定義標識符 B)定義語句出錯,printF不能用作用戶自定義標識符 C)定義語句無錯,scanf不能作為輸入函數使用 D)定義語句無錯,printf不能輸出case的值(14)表達式:(int)((double)9/2)(9)%2的值是 A)0 B)3 C)4 D)5(15)若有定義語句:int x=10。 printf(“%d,”,b=a+b)。 } 程序運行后的輸出結果是 A)0,0 B)1,0 C)3,2 D)1,217)設有定義:int a=1,b=2,c=3。 B)if(ab) {c=a,a=b,b=c。a=b。 D)if(ab) {c=a。b=c。 for (k=1。k++) switch (k) { default: c+=k case 2: c++。 case 4: c+=2。 } printf(“%d\n”,c)。amp。 else k=0。 else k=0。 else if(b=c) k=1。 else if(bc) k=1。20)有以下程序 include main() { char s[]={“012xy”}。 for(i=0。i++) if(s[i]=’a’amp。s[i]=’z’) n++。 } 程序運行后的輸出結果是 A)0 B)2 C)3 D)5(21)有以下程序 include main() { int n=2,k=0。amp。 printf(“%d %d\n”,k,n)。 B)char a=’\n’。 D)char a=’\x2d’。 c1=’A’+’8’‘4’。 printf(“%c,%d\n”,c1,c2)。 p=d++。} main() { int a=1。 printf(“%d\n”,a)。 for(i=0。i++) { max=MIN。} return max。中max未賦初值 B)賦值語句max=MIN。中判斷條件設置錯誤 D)賦值語句max=MIN。m,*q=amp。 r=p。q=r。 } 程序運行后的輸出結果是 A)1,2,1,2 B)1,2,2,1 C)2,1,2,1 D)2,1,1,2(27)若有定義語句:int a[4][10],*p,*q[4]。a[2][1](28)有以下程序 include include main() { char str[ ][20]={“One*World”, “One*Dream!”},*p=str[1]。printf(“%s\n”,p)。 for(i=0。i++) switch(i%2) { case 0:switch(a[i]%2) {case 0:a[i]++。 case 1:a[i]。 case 1:a[i[=0。i4。 printf(“\n”)。 printf(“%d,%d\n”,strlen(a),sizeof(a))。} } A)將a所指字符串賦給b所指空間 B)使指針b指向a所指字符串 C)將a所指字符串和b所指字符串進行比較 D)檢查a和b所指字符串中是否有’\0’ (33)設有以下函數 void fun(int n,char * s) {……} 則下面對函數指針的定義和賦值均是正確的是 A)void (*pf)()。 B)viod *pf()。 C)void *pf()。 D)void (*pf)(int,char)。fun。 main() { int a=3,s。s=s+f(a)。 } int f(int n) { static int a=1。 return n。 s=f(a+1)。 printf(“%d,%d\n’,s,t)。int y。}。 B)struct ord {int x。int z。 C)struct ord {int x。int z。 D)struct {int x。int z。(37)設有定義:char *c。c=str。 C)c=getchar()。 (38)有以下程序 include include struct A { int a。 double c。 struct A f(struct A t)。 a=f(a)。 } struct A f(struct A t) ( =1002。=。 ) 程序運行后的輸出結果是 A)1001,ZhangDa, B)1001,ZhangDa, C)1001,ChangRong, D)1001,ChangRong, (39)若
點擊復制文檔內容
試題試卷相關推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1