




全文預覽已結束
下載本文檔
版權說明:本文檔由用戶提供并上傳,收益歸屬內容提供方,若內容存在侵權,請進行舉報或認領
文檔簡介
第第 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 全局變量 局部變量 靜態變量 動態變量 4 auto static register extern 5 外部變量 6 編譯 運行 3 閱讀程序 指出結果 閱讀程序 指出結果 1 15 2 5 3 5 4 3 4 i 5 i 2 i 2 i 4 i 2 5 求水仙花數 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. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯系上傳者。文件的所有權益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網頁內容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
- 4. 未經權益所有人同意不得將文件中的內容挪作商業或盈利用途。
- 5. 人人文庫網僅提供信息存儲空間,僅對用戶上傳內容的表現方式做保護處理,對用戶上傳分享的文檔內容本身不做任何修改或編輯,并不能對任何下載內容負責。
- 6. 下載文件中如有侵權或不適當內容,請與我們聯系,我們立即糾正。
- 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 《行路難(其一)》教學設計
- 《電子元件封裝技術》課件
- 中草藥有效成分的提取與結構鑒定課件
- 《優化客戶溝通技巧》課件
- 安全培訓個人總結
- 航空事故處理考核試卷
- 小草的課件教學課件
- 2025年煤炭采掘機械設備合作協議書
- 《T教育講座》課件
- 運維安全問題
- 醫院新媒體管理辦法
- 全國粵教清華版初中信息技術八年級下冊第1單元第1節《從互聯網到物聯網》說課稿
- 2025年中天合創煤炭分公司面向社會公開招聘煤炭專業技術人員管理單位筆試遴選500模擬題附帶答案詳解
- 基于OBE理念的古代漢語教學大綱設計
- 《智能財務與經營分析》課程教學大綱
- 體育賽事自然災害應急預案
- 生命科學簡史知到智慧樹章節測試課后答案2024年秋中國科學技術大學
- 2024年協會工作年終總結(2篇)
- 化學教學論試卷(共7篇)
- GB/T 44591-2024農業社會化服務社區生鮮店服務規范
- 《剪映專業版:短視頻創作案例教程(全彩慕課版)》 課件 第6章 創作生活Vlog
評論
0/150
提交評論