




全文預(yù)覽已結(jié)束
下載本文檔
版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)
文檔簡介
第第 4 章習題參考答案章習題參考答案 1 單項選擇題 單項選擇題 1 D 2 D 3 D 4 B 5 D 6 B 7 A 8 D 9 C 10 D 11 B 12 D 13 A 14 B 2 填空題 填空題 1 2 2 嵌套 遞歸 3 全局變量 局部變量 靜態(tài)變量 動態(tài)變量 4 auto static register extern 5 外部變量 6 編譯 運行 3 閱讀程序 指出結(jié)果 閱讀程序 指出結(jié)果 1 15 2 5 3 5 4 3 4 i 5 i 2 i 2 i 4 i 2 5 求水仙花數(shù) 6 5 5 5 7 30 8 0 10 1 11 2 12 4 程序填空 程序填空 1 float fun float float x y x y z y z y 2 x x x 1 3 s 0 a a b 5 編程題 編程題 1 include unsigned int fun unsigned int int main unsigned int s scanf u printf u n fun s return 0 unsigned int fun unsigned int s unsigned int p 0 while s 0 p p s 10 s s 10 return p 2 include include include void f1 float float float float void f2 float float float float void f3 float float float float int main float a b c d scanf f f f if a 0 printf 不是一元二次方程 n exit 0 d b b 4 a c if d 0 f1 a b c d else if d 0 f2 a b c d else f3 a b c d return 0 void f1 float a float b float c float d float x1 x2 x1 b sqrt d 2 a x2 b sqrt d 2 a printf 2f 2f n x1 x2 void f2 float a float b float c float d float x1 x2 x1 b 2 a x2 b 2 a printf 2f 2f n x1 x2 void f3 float a float b float c float d float x1 x2 x1 b 2 a x2 sqrt d 2 a printf 2f i 2f n x1 x2 printf 2f i 2f n x1 x2 3 include double p int double int main int n double x do scanf d while n 0 scanf lf printf lf n p n x return 0 double p int n double x double pn if n 0 pn 1 else if n 1 pn x else pn 2 n 1 x p n 1 x n 1 p n 2 x n return pn 4 include define RATE 0 053 double fun float void display float int int main float dep int season scanf f d display dep season return 0 double fun float d return d RATE void display float d int s int i printf 季度 利息 余額 n printf n for i 1 i s i printf 4d 2f 2f n i fun d fun d i d printf n 5 include double fun void int main printf lf n fun return 0 double fun void double s 0 int n 1 while double 2 n 1 2 n 2 n 1e 4 s s double 2 n 1 2 n 2 n n return s 6 include int fun int int main int w scanf
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
- 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 就業(yè)項目策劃管理辦法
- 律師辦案資金管理辦法
- 盆栽西瓜種植管理辦法
- 土地經(jīng)營確權(quán)管理辦法
- 人教版三年級下冊語文主題活動計劃
- 人教版四年級綜合實踐活動學期計劃
- 小學一年級道德與法治課程內(nèi)容優(yōu)化計劃
- 湘教版四年級上冊音樂教學設(shè)計計劃
- 小學四年級音樂課程體系建設(shè)計劃
- 高二生物必修三課程資源開發(fā)計劃
- 《生物活性物質(zhì)》課件
- 廣東省珠海市香洲區(qū)2023-2024學年五年級下學期語文期末考試試卷(含答案)
- 2025天然氣管道工程安裝合同協(xié)議書
- 2025-2030中國煙草行業(yè)市場深度調(diào)研及發(fā)展策略研究報告
- 導熱油購買合同協(xié)議
- 駐唱歌手合同協(xié)議
- 銀行安全培訓
- 燃氣行業(yè)法律法規(guī)培訓
- 【初中地理】七年級地理下冊全冊期末總復(fù)習(課件)-2024-2025學年七年級地理課件(人教版2024年)
- 2024年隴南市武都區(qū)佛崖鎮(zhèn)招聘專職化村文書筆試真題
- 《煙花爆竹安全》課件
評論
0/150
提交評論