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

正文內容

c語言概述練習題-預覽頁

2025-09-05 19:06 上一頁面

下一頁面
 

【正文】 =t; t=b; b=a; D. t=b; b=a; a=t; int k=7,x=12;,下列表達式中,計算結果為 0的是 _________________。amp。1 D.!(58)||(28) 28.設 int a=10,b=11,c=12;,表達式 (a+b)camp。 x20 10||x20 10amp。 2 3 2 3 x≥ y≥ z,應使用的 C++表達式是 ____________。(y=z) int x=43,y=0; char ch=’ A’ ;,則表達式 (x=yamp。!y)的值是 __________。(b0) amp。amp。a15 D.!(a=10)amp。amp。amp。 k=(a++=0)amp。 system(“ pause” )。y ^y int a=4,float x=,y=;,則表達式 a+(int)((int)(x)+y)(int)(xy)的值為 ________。 coutu” ,” v” ,” wendl。 3.字符串常量的結束符為 _________________。double d。 include iostream using namespace std。 coutd*bendl。 include iostream using namespace std。 int i。 return 0。 16,請將程序填完整。 z=a/2+b*x/y+1/2。 } ___________________。y=xy。 return 0。 include iostream include iomanip using namespace std。 couthexcendl。 include iostream using namespace std。 b=a。 第 6 頁 共 27 頁 } a的后 6位存放到變量中。 cinocta。 return 0。 、選擇結構和遞歸結構 、順序結構和過程結構 、選擇結構和循環(huán)結構 、嵌套結構和遞歸結構 2.設已定義整型變量 a、 b、 c、 x,下列程序段運行后 x的值是 _______________。 if(c) x=3。char c=’ D’ ;,則執(zhí)行的語句后, d的值是 _______________。break。 } int i;,下面程序段的運行結果是 __________。 coutiendl。} 9 8 8 7 9 8 7 8 7 6 int x=3。 0 2 dowhile循環(huán)的敘述中,正確的是 _______________。 else y=2。 for(int i=0。 void main() { int a,b,c,i。i+=2) { a+=i。 system(“ pause” )。 include iostream using namespace std。 } system(“ pause” )。 for(i=0。 void main() { int x=3,y=0,z=0。 } ,若從鍵盤輸入 3和 4,則輸出為 ____________________。 s=a。 system(“ pause” )。 for(i=1。 default:a+=5。 include iostream using namespace std。 j。 } _________________________。i=50。 第 10 頁 共 27 頁 } ________________。i。 } _____________________。y+=a。 system(“ pause” )。 do{coutx。 include iostream using namespace std。i++) for(j=0。 system(“ pause” )。 for(a=1,b=1。continue。 include iostream using namespace std。 } cout” x=” x” ,y=” y” ,a=” aendl。 cinx。 else y=3。請將程序修改正確,以得到正確的輸出結果。i100。 system(“ pause” )。 for(int n=1。 system(“ pause” )。 4.編制程序打印出 100以內的所有素數。 int型,變量 z為 float型,則該函數體內的語句 return(z)返回值的類型是 __________。 include iostream using namespace std。 coutaendl。 include iostream using namespace std。 coutd” ” 。 coutdendl。 第 14 頁 共 27 頁 r=func(func(x,y),z)。 __________。 a=c++,b++。i2。 ,則該變量的存儲類型是__________。 statc int c=3。 for(i=0。 } ,將出現的情況為 __________。 function(val)。} __________。 } int main() { int w=5。 ,調用語句被替換成內聯函數的函數體 __________。 include cmath double pi(long n) { double s=。k++) s=s+_____________。 void f(int x,int y,int cp,int dp=8) { cp=x*x+y*y。 coutc” ” dendl。 f=f*n。i=5。double z。 return z。 a+=2。cc4。 include iostream using namespace std。 return s。 } __________。 { int i=5,j=6。 } __________。k=2。 n+=x+y。 int a=5,b=6。 cout” max=” cendl。 } static int a=8,b=7。 test(2,’ B’ )。 三、編程題 ,要求在主函數中輸入一個整數,利用自定義的函數 prime()判斷該整數是否為素數,若是素數,函數返回 1,否則返回 0。則數組 x在內存中所占字節(jié)數為 _________。則字符串 s所占的字節(jié)數是 _________。 則正確的敘述為 _________。 struct person{char name[9]。 class[3].name[1]endl。 a={one,two,three} a {one=9,two=1,three} a={“ one” ,” two” ,” three” } a {“ one” ,” two” ,” three” } : enum t1 {a1,a2=7,a3,a4=15} time。 coutmyyourhisherendl。 char b[10]。 第 20 頁 共 27 頁 ABC ABC {double a。 } } ABC a。 : char s[100],d[100]。 j++。 include string int main() { char str[80],m。i 【 1】 。 } coutstrendl。 include string int main() { char a[]=” clanguage” ,t。i=k2。a[i]=a[j]。 } ,則變量 a在內存中所占的字節(jié)數是 _________。 }a。i=0。 int main() { int a[4][4]={{1,3,5},{2,4,6},{3,5,7}}。 for(i=1。j++) s+=a[i][j]。 for(k=1。 int main() { char ch[7]={“ 65ab21” }。amp。 coutsendl。}um[2]={1,3,2,7}。int b。 t=s[0].a+a[1].b。 b[5]=0。 int main() { int a[3][3]={1,3,5,7,9,11,13,15,17},i,j。i++) for(j=1。 } 5個人的學號(整型)和 C語言課的考試成績(整型),計算并輸出平均分,以及大于等于平均分的學生的學號和分數。 int c。 for(k=1。 av=av+a[k].c。k=5。 ,要求利用結構數組實現輸入三個人的姓名和年齡,并輸出三個人中年齡最大者的姓名和年齡。a。i。j =**p 3. A. B. C. D. _________。 A. B. C. D. _________。 A. B. C. D. _________。 A. B. C. D. _________。 A. B. C. D. _________。 A. B. C. D. _________。 A. B. C. D. _________。 int a=2, b=2;則 ++a+b的結果是 _____________, a的值是 _______________, b的值是 _______________。 A.\yes\or\No\ B.\39。+i*f的值的數據類型是 ________。int a,b。 } (x) { case :cout*\n。 } (a+b) { case 1:cout*\n。 (a) { case a:a++。 } (a+b) { 第 26 頁 共 27 頁 case 1:a+b。 } (a/10+b) { case 5:a/5。 ,它將退出該重循環(huán); switch語句中,它將退出 switch語句; if體內,它將退出 if語句; 次 for循環(huán)的次數為 ______。i=5。 int i=5。 for循環(huán)的循環(huán)體執(zhí)行次數為 ______。 ; ; ; : fun(a+b,(x,y),fun(n+k,d,(a,b)))。 include iostream using namespace std。k) { 第 27 頁 共 27 頁 switch(k) { case 1: case 4: case 7:s++。break。 void print(int n) { if(n!=0) { print(n1)。 coutendl。 }
點擊復制文檔內容
研究報告相關推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1