civil96 板


LINE

以下由本人隨意豪洨完成的 答案並非為官方公佈之解答 如果答案有錯請麻煩推文指教 給大家當參考~ 請記得開燈喔~ 1.  (i) x - x*y + y - 5 (ii) y = 0.2*x*x + (b-a)*x /(b+a) + a/b 2. First, you learn it because it's fun. Second, you learn programming language so you can express your ideas to accomplish task with computer. 3. #include <fstream> using namespace std; int main() { ofstream fout("output.txt"); fout << "Einstein said \"make everything as simple as possible,"; fout << " but not simpler.\"" << endl; fout << "Niels Bohr said \"prediction is very difficult, especially of "; fout << "the future.\"" << endl; fout.close(); return 0; } 4. #include <iostream> using namespace std; int main() { int input; cin >> input ; if (input%2==0) cout <<"This is an even number."<< endl; else cout <<"This is an odd number."<< endl; return 0; } 5. #include <iostream> using namespace std; int main() { long double i, n, x, sum; const long double PI = 3.14159265358979323846243; cout << "Please input n: "; cin >> n; cout << endl; for (i=0; i<=n; i++) { x = (i - 0.5)/n; sum = sum + 4/(1+x*x)/n; } cout <<"Pi estimate =" << sum <<endl; cout <<"Percentage error = " << (sum - PI)*100 <<"%" << endl; return 0; } -- http://www.wretch.cc/blog/andrewchiang ▁▂▁ ├┤ ◤ ╮ ▁▂▁ ⊙ ︵ ──◆ 巛◆ ╰╯ ) ▇▆▅▄ ██████▁ ⊙ ︶ ▇▆▅▆ ◣ ╯ --



※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.112.241.112
1F:推 ivia:還可以這樣討論的喔= = 03/18 21:09
2F:推 c040723:交出去的時候會有很多一樣的答案吧(茶) 03/18 21:16
3F:→ andrewchiang:這是模擬考題啊 03/18 21:18
4F:推 leethomas:讓我想起高中電腦課的時候 大家都在家族PO答案XD 03/18 21:28
5F:推 shamangary:實在是太強啦 03/18 22:23
6F:推 tomroy:這不是應該低調嗎? 03/18 22:46
7F:→ andrewchiang: D調 03/18 23:30
8F:→ joad:" Why you learn C++,Guys? " " Because I'm BORING!! " 03/18 23:32
※ 編輯: andrewchiang 來自: 140.112.241.112 (03/18 23:37)
9F:推 LonelyDream:我把你第五題輸入9999999999run超久 03/18 23:42
10F:→ andrewchiang:是跑不動... 03/19 00:11
11F:推 aa1052v:低調不太成功 要每行都打喔 03/19 00:23
12F:→ andrewchiang:懶得打... 03/19 08:50







like.gif 您可能會有興趣的文章
icon.png[問題/行為] 貓晚上進房間會不會有憋尿問題
icon.pngRe: [閒聊] 選了錯誤的女孩成為魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一張
icon.png[心得] EMS高領長版毛衣.墨小樓MC1002
icon.png[分享] 丹龍隔熱紙GE55+33+22
icon.png[問題] 清洗洗衣機
icon.png[尋物] 窗台下的空間
icon.png[閒聊] 双極の女神1 木魔爵
icon.png[售車] 新竹 1997 march 1297cc 白色 四門
icon.png[討論] 能從照片感受到攝影者心情嗎
icon.png[狂賀] 賀賀賀賀 賀!島村卯月!總選舉NO.1
icon.png[難過] 羨慕白皮膚的女生
icon.png閱讀文章
icon.png[黑特]
icon.png[問題] SBK S1安裝於安全帽位置
icon.png[分享] 舊woo100絕版開箱!!
icon.pngRe: [無言] 關於小包衛生紙
icon.png[開箱] E5-2683V3 RX480Strix 快睿C1 簡單測試
icon.png[心得] 蒼の海賊龍 地獄 執行者16PT
icon.png[售車] 1999年Virage iO 1.8EXi
icon.png[心得] 挑戰33 LV10 獅子座pt solo
icon.png[閒聊] 手把手教你不被桶之新手主購教學
icon.png[分享] Civic Type R 量產版官方照無預警流出
icon.png[售車] Golf 4 2.0 銀色 自排
icon.png[出售] Graco提籃汽座(有底座)2000元誠可議
icon.png[問題] 請問補牙材質掉了還能再補嗎?(台中半年內
icon.png[問題] 44th 單曲 生寫竟然都給重複的啊啊!
icon.png[心得] 華南紅卡/icash 核卡
icon.png[問題] 拔牙矯正這樣正常嗎
icon.png[贈送] 老莫高業 初業 102年版
icon.png[情報] 三大行動支付 本季掀戰火
icon.png[寶寶] 博客來Amos水蠟筆5/1特價五折
icon.pngRe: [心得] 新鮮人一些面試分享
icon.png[心得] 蒼の海賊龍 地獄 麒麟25PT
icon.pngRe: [閒聊] (君の名は。雷慎入) 君名二創漫畫翻譯
icon.pngRe: [閒聊] OGN中場影片:失蹤人口局 (英文字幕)
icon.png[問題] 台灣大哥大4G訊號差
icon.png[出售] [全國]全新千尋侘草LED燈, 水草

請輸入看板名稱,例如:BuyTogether站內搜尋

TOP