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

正文內(nèi)容

c語言程序設(shè)計(jì)a課程形成性考核作業(yè)-資料下載頁

2025-07-07 11:43本頁面
  

【正文】 tBOOK**x=amp。book。2.假定有“structBOOK{chartitle[40]。floatprice。}book?!?,則正確的語句為()。A.structBOOKx=amp。book。 B.structBOOK*x=amp。book。C.structBOOKx=calloc(BOOK)。 D.structBOOK*x=BOOK。3.表示文件結(jié)束的符號常量為()。A.eof B.Eof C.EOF D.feof4.C語言中系統(tǒng)函數(shù)fopen()是()一個(gè)數(shù)據(jù)文件的函數(shù)。A.讀取 B.寫入 C.關(guān)閉 D.打開5.從一個(gè)數(shù)據(jù)文件中讀入以換行符結(jié)束的一行字符串的函數(shù)為()。A.gets() B.fgets() C.getc() D.fgetc()6.向一個(gè)二進(jìn)制文件寫入信息的函數(shù)fwrite()帶有()參數(shù)。A.1 B.2 C.3 D.4二、填空題1.假定一個(gè)結(jié)構(gòu)類型的定義為“structA{inta,b。A*c。}?!?,則該類型的大小為__________字節(jié)。2.假定一個(gè)結(jié)構(gòu)類型的定義為“struct B{int a[5],char *b。}。”,則該類型的大小為__________字節(jié)。283.假定一個(gè)結(jié)構(gòu)類型的定義為“structD{inta。union{intb。doublec。}。structD*d[2]。}?!?,則該類型的大小為__________字節(jié)。4.假定要動態(tài)分配一個(gè)類型為structWorker的具有n個(gè)元素的數(shù)組,并由r指向這個(gè)動態(tài)數(shù)組,則使用語句的表達(dá)式為__________________________________________。5.假定要訪問一個(gè)結(jié)構(gòu)x中的由a指針成員所指向的對象,則表示方法為_____________。6.假定要訪問一個(gè)結(jié)構(gòu)指針p所指向?qū)ο笾械腷指針成員所指的對象,則表示方法為___________。7.與結(jié)構(gòu)成員訪問表達(dá)式(*fp).score等價(jià)的表達(dá)式是_____________。三、寫出下列每個(gè)程序運(yùn)行后的輸出結(jié)果1.includestructWorker{charname[15]。//姓名intage。//年齡floatpay。//工資}。voidmain(){structWorkerx={wanghua,52,}。structWorkery,*p。y=x。p=amp。x。printf(%s%d%\n,)。printf(%s%d%\n,pname,page,ppay)。}輸出結(jié)果為:2.includeincludestructWorker{charname[15]。//姓名intage。//年齡29floatpay。//工資}。voidmain(){structWorkerx。char*t=louting。intd=38。floatf=493。strcpy(,t)。=d。=f。++。*=2。printf(%s%d%\n,)。}輸出結(jié)果為:3.includeincludestructWorker{charname[15]。//姓名intage。//年齡floatpay。//工資}。intLess(structWorkerr1,structWorkerr2){if()return1。elsereturn0。}voidmain(){structWorkera[4]={{abc,25,420},{def,58,638},{ghi,49,560},{jkl,36,375}}。30structWorkerx=a[0]。inti。for(i=1。i4。i++)if(Less(x,a[i]))x=a[i]。printf(%s%d%\n,)。}輸出結(jié)果為:四、寫出下列每個(gè)函數(shù)的功能1.voidQA(structWorkera[],intn){inti。for(i=0。in。i++)scanf(%s%d%f,amp。a[i].name,a[i].age,a[i].pay)。}假定結(jié)構(gòu)structWorker的定義如下:includeincludeincludestructWorker{charname[15]。//姓名intage。//年齡floatpay。//工資}。函數(shù)功能為:2.structStrNode*QB(intn){31StrNode*f,*p。if(n==0)returnNULL。f=(StrNode*)malloc(sizeof(structStrNode))。scanf(%s,fname)。p=f。while(n){p=pnext=(StrNode*)malloc(sizeof(structStrNode))。scanf(%s,pname)。}pnext=NULL。returnf。}假定結(jié)構(gòu)structStrNode的定義如下:structStrNode{charname[5]。structStrNode*next。}。函數(shù)功能為:3.structIntNode*FindMax(structIntNode*f){structIntNode*p=f。if(!f)returnNULL。f=fnext。while(f){if(fdatapdata)p=f。f=fnext。}32returnp。}假定結(jié)構(gòu)structStrNode的定義如下:structIntNode{intdata。structIntNode*next。}。函數(shù)功能為:4.intCount(structIntNode*f){intc=0。while(f){c++。f=fnext。}returnc。}假定結(jié)構(gòu)structStrNode的定義如下:structIntNode{intdata。structIntNode*next。}。函數(shù)功能為:5.structIntNode*Input(intn){structIntNode*f,*p。33f=(IntNode*)malloc(sizeof(structIntNode))。if(n==0)returnNULL。fnext=NULL。printf(從鍵盤輸入%d個(gè)整數(shù):,n)。while(n){scanf(%d,amp。(fdata))。p=f。f=(IntNode*)malloc(sizeof(structIntNode))。fnext=p。}returnfnext。}假定結(jié)構(gòu)structStrNode的定義如下:structIntNode{intdata。structIntNode*next。}。函數(shù)功能為:6.includeincludeincludevoidJA(char*fname){FILE*fout=fopen(fname,w)。chara[20]。printf()。while(1){scanf(%s,a)。34if(strcmp(a,end)==0)break。fputs(a,fout)。fputc(39。\n39。,fout)。}fclose(fout)。}voidmain(){char*p=d:\\xxk\\。JA(p)。}函數(shù)功能為:35
點(diǎn)擊復(fù)制文檔內(nèi)容
環(huán)評公示相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1