<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6329674406490224512</id><updated>2024-09-07T13:56:05.835-07:00</updated><category term="EX04.結構練習Ch2-3-1e.c"/><category term="EX05.結構練習Ch2-3-3e.c"/><category term="EX06.結構練習Ch2-3-4e.c"/><category term="EX09.指標與結構"/><category term="EX10.指標與字串"/><category term="EX11. 鏈結串列DELETENODE"/><category term="EX12. 鏈結串列insertNode"/><category term="EX13. 雙向鏈結串列"/><category term="EX14. 鏈結串列的應用- 多項式表示法"/><category term="EX15.使用堆疊的回溯控制-走迷宮"/><category term="EX16. 使用遞迥走迷宮"/><category term="EX17. 河內塔問題"/><category term="EX18. 使用陣列建立佇列"/><category term="Ex01. 迴圈"/><category term="Ex02. 頻率計數"/><category term="Ex03.陣列程式"/><category term="Ex07. 結構練習 Ch2-4e.c"/><category term="Ex08.指標與二維陣列"/><category term="課程建議"/><title type='text'>資料結構學習網誌</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>19</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-3892969641857496244</id><published>2011-06-11T21:38:00.000-07:00</published><updated>2011-06-11T21:38:13.434-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX15.使用堆疊的回溯控制-走迷宮"/><title type='text'>EX15.使用堆疊的回溯控制-走迷宮</title><content type='html'>修改程式範例: Ch5-4-1.c 為 Ch5-4-1e.c &lt;br /&gt;
1. 請使用堆疊方式找出走出迷宮的路，如下所示：&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgfR7fY4i-u96HKJj6cZYksMJum0UHK44o5UutECyCj85s4ouwVXyKGdUBpdpKbj7W6NNE-q91OQueSJOHMSgVY2cWij_9fkDFQTIwvHKpqDXuwkm-UoMBVwtcxVnmw3vyyv9XNzlgxkwh1/s1600/%25E5%259C%2596%25E7%2589%25871_%257E1.JPG&quot; imageanchor=&quot;1&quot; style=&quot;clear:left; float:left;margin-right:1em; margin-bottom:1em&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;145&quot; width=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgfR7fY4i-u96HKJj6cZYksMJum0UHK44o5UutECyCj85s4ouwVXyKGdUBpdpKbj7W6NNE-q91OQueSJOHMSgVY2cWij_9fkDFQTIwvHKpqDXuwkm-UoMBVwtcxVnmw3vyyv9XNzlgxkwh1/s320/%25E5%259C%2596%25E7%2589%25871_%257E1.JPG&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
2. 可走的路自行設定。 &lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2055013.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2055015.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2055016.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/3892969641857496244/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex15.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3892969641857496244'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3892969641857496244'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex15.html' title='EX15.使用堆疊的回溯控制-走迷宮'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgfR7fY4i-u96HKJj6cZYksMJum0UHK44o5UutECyCj85s4ouwVXyKGdUBpdpKbj7W6NNE-q91OQueSJOHMSgVY2cWij_9fkDFQTIwvHKpqDXuwkm-UoMBVwtcxVnmw3vyyv9XNzlgxkwh1/s72-c/%25E5%259C%2596%25E7%2589%25871_%257E1.JPG" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-1854776292784819673</id><published>2011-06-11T21:20:00.000-07:00</published><updated>2011-06-11T21:29:30.058-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX16. 使用遞迥走迷宮"/><title type='text'>EX16. 使用遞迥走迷宮</title><content type='html'>參考程式範例: Ch5-4-2.c &lt;br /&gt;
1. 請寫出所有完整的遞迥呼叫的執行過程： &lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQcc-M63h-YO5cga41w7hJZjxD_mFYGjes3lpX4zcsmEzrXDAr0kseWuYvCQSdjaUbQXJ4AhEoFbMd8caOi9MxQj5WCf9Wt3rrO2IVFLt2JL_-aRJ7UWOncdnQs8mxL64iqItoCmHGkSYS/s1600/image_thumb13.png&quot; imageanchor=&quot;1&quot; style=&quot;clear:left; float:left;margin-right:1em; margin-bottom:1em&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;104&quot; width=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQcc-M63h-YO5cga41w7hJZjxD_mFYGjes3lpX4zcsmEzrXDAr0kseWuYvCQSdjaUbQXJ4AhEoFbMd8caOi9MxQj5WCf9Wt3rrO2IVFLt2JL_-aRJ7UWOncdnQs8mxL64iqItoCmHGkSYS/s320/image_thumb13.png&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;https://spreadsheets.google.com/spreadsheet/ccc?key=0AkCFPdYdwkP0dDhZZTAxWVpDQmJuRkJRMUpUOFJTRkE&amp;hl=en_US
&quot;&gt;點這邊查看&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2054999.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/1854776292784819673/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex16.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/1854776292784819673'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/1854776292784819673'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex16.html' title='EX16. 使用遞迥走迷宮'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQcc-M63h-YO5cga41w7hJZjxD_mFYGjes3lpX4zcsmEzrXDAr0kseWuYvCQSdjaUbQXJ4AhEoFbMd8caOi9MxQj5WCf9Wt3rrO2IVFLt2JL_-aRJ7UWOncdnQs8mxL64iqItoCmHGkSYS/s72-c/image_thumb13.png" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-3986263033478632466</id><published>2011-06-11T20:57:00.000-07:00</published><updated>2011-06-18T21:35:32.803-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX18. 使用陣列建立佇列"/><title type='text'>EX18. 使用陣列建立佇列</title><content type='html'>修改程式範例: Ch6-2-1.c 為 Ch6-2-1e.c &lt;br /&gt;
1.請使用陣列方式建立佇列 &lt;br /&gt;
2.請於程式中加入功能如下:  [1]存入 [2]取出 [3]顯示全部…&lt;br /&gt;
[1]存入 :  詢問輸入存入值 &lt;br /&gt;
[2]取出 :  顯示取出佇列元素 &lt;br /&gt;
[3]顯示全部 :顯示輸入佇列的元素/取出佇列的元素/剩下佇列的元素 &lt;br /&gt;
3.功能參考(ch6-2-2.c)&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2090079.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2090080.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/3986263033478632466/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex18.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3986263033478632466'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3986263033478632466'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex18.html' title='EX18. 使用陣列建立佇列'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-3424032839923235270</id><published>2011-06-11T20:55:00.000-07:00</published><updated>2011-06-18T21:22:28.880-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX17. 河內塔問題"/><title type='text'>EX17. 河內塔問題</title><content type='html'>修改程式範例: Ch5-5.c 為 Ch5-5e.c &lt;br /&gt;
1.請建立遞迥函數解出5個盤子的河內塔問題 &lt;br /&gt;
2.請參考如下方式用Excel寫出所有完整的遞迥呼叫的執行過程 &lt;br /&gt;
3.執行過程Excel檔請在Google 文件設為共用並將url置於網頁上&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhSmavX1gmab9wTVXhJg0Pxy5GQpebcmVOORnQ7BtbBA0Qj_cCUjL0UXyinu6ltcCcJdGltVHnwFm_56eakElAkMariq0wkcByGyhZvrfgWkKo1MOKZXslG5M9heS_R5Grf-WnBna6utET7/s1600/hanoiTower%255B11%255D.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;134&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhSmavX1gmab9wTVXhJg0Pxy5GQpebcmVOORnQ7BtbBA0Qj_cCUjL0UXyinu6ltcCcJdGltVHnwFm_56eakElAkMariq0wkcByGyhZvrfgWkKo1MOKZXslG5M9heS_R5Grf-WnBna6utET7/s320/hanoiTower%255B11%255D.jpg&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;a href=&quot;https://spreadsheets.google.com/spreadsheet/ccc?key=0AkCFPdYdwkP0dHRTSFRFQ0djZjQ4cUNfS3ZHdGRoVFE&amp;hl=en_US&quot;&gt;點我&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/3424032839923235270/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex17.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3424032839923235270'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3424032839923235270'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex17.html' title='EX17. 河內塔問題'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhSmavX1gmab9wTVXhJg0Pxy5GQpebcmVOORnQ7BtbBA0Qj_cCUjL0UXyinu6ltcCcJdGltVHnwFm_56eakElAkMariq0wkcByGyhZvrfgWkKo1MOKZXslG5M9heS_R5Grf-WnBna6utET7/s72-c/hanoiTower%255B11%255D.jpg" height="72" width="72"/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8161248382643133636</id><published>2011-06-10T01:51:00.000-07:00</published><updated>2011-06-10T01:51:32.349-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX14. 鏈結串列的應用- 多項式表示法"/><title type='text'>EX14. 鏈結串列的應用- 多項式表示法</title><content type='html'>修改程式範例: Ch4-6.c 為 Ch4-6e.c &lt;br /&gt;
請使用含開頭節點的環狀串列結構儲存下列多項式，如下所示： &lt;br /&gt;
(1) f(x)  = X4+5X3+4X+3 &lt;br /&gt;
(2) g(x) = 5X2+2X+5 &lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2046767.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2046772.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/2046773.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8161248382643133636/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex14.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8161248382643133636'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8161248382643133636'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/06/ex14.html' title='EX14. 鏈結串列的應用- 多項式表示法'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-3438885512264905546</id><published>2011-05-31T03:48:00.000-07:00</published><updated>2011-05-31T03:48:34.455-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX13. 雙向鏈結串列"/><title type='text'>EX13. 雙向鏈結串列</title><content type='html'>修改程式範例: Ch4-5-3.c 為 Ch4-5-3e.c &lt;br /&gt;
1.將雙向鏈結串列的所有操作整合 &lt;br /&gt;
2.整合的功能如下: &lt;br /&gt;
   [F] 往下移動 &lt;br /&gt;
   [B] 往前移動 &lt;br /&gt;
   [A] 新增節點 &lt;br /&gt;
   [D] 刪除節點 &lt;br /&gt;
   [R] 重設 &lt;br /&gt;
   [V] 節點值 &lt;br /&gt;
   [E] 離開 &lt;br /&gt;
3.參考Ch4-5-1.c Ch4-5-2.c Ch4-5-3.c &lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1997509.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1997515.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1997517.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1997519.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1997522.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/3438885512264905546/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex13.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3438885512264905546'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/3438885512264905546'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex13.html' title='EX13. 雙向鏈結串列'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8043654757777134820</id><published>2011-05-20T07:02:00.000-07:00</published><updated>2011-05-20T07:02:54.890-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX12. 鏈結串列insertNode"/><title type='text'>EX12. 鏈結串列insertNode</title><content type='html'>修改程式範例: Ch4-3-3.c 為 Ch4-3-3e.c &lt;br /&gt;
&lt;br /&gt;
修改 Ch4-3-3.c 中include的 “insertNode.c”程式 &lt;br /&gt;
將”情況2: 插入最後一個節點”及”情況3: 插入成為中間節點 “的程式碼判斷改為同時指向ptr-&gt;next. &lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1931780.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1931784.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1931787.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1931788.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8043654757777134820/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex12-insertnode.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8043654757777134820'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8043654757777134820'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex12-insertnode.html' title='EX12. 鏈結串列insertNode'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-384091500942981710</id><published>2011-05-07T21:29:00.000-07:00</published><updated>2011-05-07T21:48:35.367-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX11. 鏈結串列DELETENODE"/><title type='text'>EX11. 鏈結串列DELETENODE</title><content type='html'>修改程式範例: Ch4-3-2.c 為 Ch4-3-2e.c &lt;br /&gt;
1.修改 Ch4-3-2.c 中include的 “deleteNode.c”程式&lt;br /&gt;
2.將”情況2: 刪除最後一個節點”及”情況3: 刪除中間節點 “的程式碼判斷改為同時指向 ptr-&amp;gt;next.&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1876942.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1876944.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1876951.js&#39;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1876947.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/384091500942981710/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex11-deletenode.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/384091500942981710'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/384091500942981710'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/05/ex11-deletenode.html' title='EX11. 鏈結串列DELETENODE'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8733720210560135396</id><published>2011-04-14T11:14:00.000-07:00</published><updated>2011-04-14T11:14:08.418-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX10.指標與字串"/><title type='text'>EX10.指標與字串</title><content type='html'>修改程式範例: Ch3-4-1.c 為 Ch3-4-1e.c &lt;br /&gt;
&lt;br /&gt;
1. 將字串複製: &lt;br /&gt;
&lt;br /&gt;
於while程式段中的ptr1修改為如ptr的遞增運算方式 &lt;br /&gt;
&lt;br /&gt;
2. 如: &lt;br /&gt;
&lt;br /&gt;
加法運算 遞增運算 &lt;br /&gt;
&lt;br /&gt;
*(ptr1+i) ; *ptr1++; &lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1795359.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8733720210560135396/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex10.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8733720210560135396'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8733720210560135396'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex10.html' title='EX10.指標與字串'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-4613079815144244334</id><published>2011-04-14T11:10:00.000-07:00</published><updated>2011-04-14T11:10:36.672-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX09.指標與結構"/><title type='text'>EX09.指標與結構</title><content type='html'>&lt;span style=&quot;font-size: medium;&quot;&gt;&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;&lt;strong&gt;修改程式範例: Ch3-3.c 為 Ch3-3e.c&lt;/strong&gt; &lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;1.增加電話結構的宣告 &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; struct phone /* phone結構 */ &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; { &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; char phone1[15]; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; char phone2[15]; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; } &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;2.將 struct label 增加phone結構成員: &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; struct phone callno; &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;font-family: 微軟正黑體; font-size: medium;&quot;&gt;3.使用結構變數和指標來存取&lt;/span&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1795349.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/4613079815144244334/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex09.html#comment-form' title='0 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/4613079815144244334'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/4613079815144244334'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex09.html' title='EX09.指標與結構'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-411052285060984201</id><published>2011-04-02T20:45:00.000-07:00</published><updated>2011-05-08T01:40:32.327-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ex08.指標與二維陣列"/><title type='text'>Ex08.指標與二維陣列</title><content type='html'>&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0.35in; margin-top: 7pt; mso-line-break-override: none; mso-vertical-align-alt: auto; punctuation-wrap: hanging; text-align: left; text-indent: -0.35in; unicode-bidi: embed;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;修改程式範例&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;: Ch3-2-2.c &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;為 &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;Ch3-2-2e.c &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; mso-line-break-override: restrictions; punctuation-wrap: simple; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;span style=&quot;color: #dd8047; font-family: +mj-lt; mso-color-index: 5; mso-special-format: &amp;quot;numbullet3,1&amp;quot;;&quot;&gt;1.&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;將程式改為完整的九九乘法表&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; mso-line-break-override: restrictions; punctuation-wrap: simple; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;span style=&quot;color: #dd8047; font-family: +mj-lt; mso-color-index: 5; mso-special-format: &amp;quot;numbullet3,1&amp;quot;;&quot;&gt;2.&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;增加顯示 &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;i, j, i+1, j+1 &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;及 &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;i&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;COLS+j&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;的值如下&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-bidi-font-family: +mn-cs; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;:&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;table border=&quot;0&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; style=&quot;border-collapse: collapse; width: 640px;&quot;&gt;&lt;colgroup&gt;&lt;col span=&quot;5&quot; style=&quot;mso-width-source: userset; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;/colgroup&gt;&lt;tbody&gt;
&lt;tr height=&quot;55&quot; style=&quot;height: 41.58pt; mso-height-source: userset;&quot;&gt;&lt;td class=&quot;oa1&quot; height=&quot;55&quot; style=&quot;height: 41.58pt; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;i&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;j &lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;i+1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; line-height: normal; margin: 0pt 0in; mso-line-break-override: none; mso-vertical-align-alt: auto; punctuation-wrap: hanging; text-align: center; text-indent: 0in; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;j+1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;i&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;*&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;COLS+j&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr height=&quot;55&quot; style=&quot;height: 41.58pt; mso-height-source: userset;&quot;&gt;&lt;td class=&quot;oa1&quot; height=&quot;55&quot; style=&quot;height: 41.58pt; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr height=&quot;55&quot; style=&quot;height: 41.58pt; mso-height-source: userset;&quot;&gt;&lt;td class=&quot;oa1&quot; height=&quot;55&quot; style=&quot;height: 41.58pt; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr height=&quot;55&quot; style=&quot;height: 41.58pt; mso-height-source: userset;&quot;&gt;&lt;td class=&quot;oa1&quot; height=&quot;55&quot; style=&quot;height: 41.58pt; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;0&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;1&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;3&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;2&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr height=&quot;55&quot; style=&quot;height: 41.58pt; mso-height-source: userset;&quot;&gt;&lt;td class=&quot;oa1&quot; height=&quot;55&quot; style=&quot;height: 41.58pt; width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;…&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;…&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;…&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;…&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;oa1&quot; style=&quot;width: 96pt;&quot; width=&quot;128&quot;&gt;&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0in; margin-top: 0pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: center; unicode-bidi: embed; word-break: normal;&quot;&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: en-US; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt;…&lt;/span&gt;&lt;span style=&quot;color: black; font-family: 微軟正黑體; font-weight: bold; language: zh-TW; mso-ascii-font-family: 微軟正黑體; mso-color-index: 1; mso-fareast-font-family: 微軟正黑體; mso-font-kerning: 12.0pt;&quot;&gt; &lt;/span&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;script src=&#39;http://pastie.org/1771974.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/411052285060984201/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex8.html#comment-form' title='2 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/411052285060984201'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/411052285060984201'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/04/ex8.html' title='Ex08.指標與二維陣列'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-7734956914752094998</id><published>2011-03-29T00:10:00.000-07:00</published><updated>2011-03-29T00:18:30.371-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ex07. 結構練習 Ch2-4e.c"/><title type='text'>Ex07. 結構練習 Ch2-4e.c</title><content type='html'>&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.35in; margin-top: 7pt; text-align: left; text-indent: -0.35in; unicode-bidi: embed;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;修改程式範例&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Tw Cen MT&amp;quot;;&quot;&gt;: Ch2-4.c&amp;nbsp; &lt;/span&gt;&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;為&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Tw Cen MT&amp;quot;;&quot;&gt;Ch2-4e.c &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: white;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;1.&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;假設有一個&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Tw Cen MT&amp;quot;;&quot;&gt;6 X 9&lt;/span&gt;&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;的稀疏矩陣，如下圖所示：&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Tw Cen MT&amp;quot;;&quot;&gt; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: white;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;2.&lt;span style=&quot;font-family: 微軟正黑體;&quot;&gt;請使用結構陣列的壓縮表示法建立稀疏矩陣的內容。&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;/div&gt;&lt;div style=&quot;color: white; direction: ltr; margin-bottom: 0pt; margin-left: 0.56in; margin-top: 7pt; text-align: left; text-indent: -0.56in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;/div&gt;&lt;br /&gt;
&lt;script src=&#39;http://pastie.org/1729916.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/7734956914752094998/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex07-ch2-4ec.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7734956914752094998'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7734956914752094998'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex07-ch2-4ec.html' title='Ex07. 結構練習 Ch2-4e.c'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-1011190461647842268</id><published>2011-03-24T02:12:00.001-07:00</published><updated>2011-03-24T02:12:38.589-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX06.結構練習Ch2-3-4e.c"/><title type='text'>EX06.結構練習Ch2-3-4e.c</title><content type='html'>&lt;script src=&#39;http://pastie.org/1707433.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/1011190461647842268/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex06ch2-3-4ec.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/1011190461647842268'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/1011190461647842268'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex06ch2-3-4ec.html' title='EX06.結構練習Ch2-3-4e.c'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8369167388767193927</id><published>2011-03-24T00:24:00.000-07:00</published><updated>2011-03-24T00:24:23.462-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX05.結構練習Ch2-3-3e.c"/><title type='text'>EX05.結構練習Ch2-3-3e.c</title><content type='html'>&lt;script src=&#39;http://pastie.org/1707188.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8369167388767193927/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex05ch2-3-3ec.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8369167388767193927'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8369167388767193927'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex05ch2-3-3ec.html' title='EX05.結構練習Ch2-3-3e.c'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8769163835554809259</id><published>2011-03-24T00:00:00.000-07:00</published><updated>2011-03-24T00:00:50.523-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="EX04.結構練習Ch2-3-1e.c"/><title type='text'>EX04.結構練習Ch2-3-1e.c</title><content type='html'>&lt;script src=&#39;http://pastie.org/1707147.js&#39;&gt;&lt;/script&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8769163835554809259/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex04ch2-3-1ec.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8769163835554809259'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8769163835554809259'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex04ch2-3-1ec.html' title='EX04.結構練習Ch2-3-1e.c'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8564969443230078638</id><published>2011-03-05T22:18:00.000-08:00</published><updated>2011-03-26T21:34:34.763-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ex03.陣列程式"/><title type='text'>Ex03.陣列程式</title><content type='html'>Ex03.陣列程式 &lt;br /&gt;
修改程式範例: Ch2-1-2.c 為Ch2-1-2e.c &lt;br /&gt;
1.增加成績對調的功能 &lt;br /&gt;
2.於選單增加”成績對調”選項 &lt;br /&gt;
3.詢問欲對調成績的學生學號 &lt;br /&gt;
4.將輸入的學生學號對應的成績執行對調&lt;br /&gt;
對調方式:&lt;br /&gt;
temp=scores[std1];&lt;br /&gt;
scores[std1]=scores[std2];&lt;br /&gt;
scores[std2]=temp;&lt;br /&gt;
ANS:&lt;br /&gt;
#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;
#include &amp;lt;stdlib.h&amp;gt;&lt;br /&gt;
/* 主程式 */&lt;br /&gt;
int main() {&lt;br /&gt;
&amp;nbsp;&amp;nbsp; /* 學生成績陣列 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int scores[10] = {76,85,90,67,59,79,82,95,91,65};&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int num;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 學號 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int grade;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int i, choice;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 選項 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int n,temp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 對調 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; int doit = 1;&lt;br /&gt;
&amp;nbsp;&amp;nbsp; /* 執行操作的主迴圈 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp; while ( doit ) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;----選單----\n&quot;); &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;1: 查詢成績\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;2: 修改成績\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;3: 成績對調\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;4: 顯示成績\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;5: 離開作業\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;請輸入選項( 1 到 5 ). ==&amp;gt; &quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scanf(&quot;%d&quot;, &amp;amp;choice); &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (choice &amp;lt; 4 ) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;請輸入學生學號( 0 到 9). ==&amp;gt; &quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scanf(&quot;%d&quot;, &amp;amp;num);&amp;nbsp; /* 讀入學號 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; switch( choice ) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case 1:&amp;nbsp; /* 查詢成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; grade = scores[num];&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 取得成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;學生成績: %d\n&quot;, grade);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case 2:&amp;nbsp; /* 修改成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; grade = scores[num];&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;原來學生成績: %d\n&quot;, grade);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;輸入新成績. ==&amp;gt; &quot;);/* 讀取新成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scanf(&quot;%d&quot;, &amp;amp;grade);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scores[num] = grade;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* 更新成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case 3:&amp;nbsp; /* 成績對調 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; grade = scores[num];&amp;nbsp; /* 取得成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;請輸入欲對調學生之學號. ==&amp;gt; &quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scanf(&quot;%d&quot;, &amp;amp;n);&amp;nbsp; /* 讀入欲對調學生之學號 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; temp = scores[num];&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scores[num] = scores[n];&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; scores[n] = temp;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case 4:&amp;nbsp; /* 顯示成績 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;學生成績: \n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for ( i = 0; i &amp;lt; 10; i++ )&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;%d:%d &quot;, i, scores[i]);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; printf(&quot;\n&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; case 5:&amp;nbsp; /* 結束作業 */&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; doit = 0;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&amp;nbsp;&amp;nbsp; }&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp; system(&quot;PAUSE&quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp; return 0; &lt;br /&gt;
}</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8564969443230078638/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex03.html#comment-form' title='2 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8564969443230078638'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8564969443230078638'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/03/ex03.html' title='Ex03.陣列程式'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-8791793347145699039</id><published>2011-02-26T22:34:00.000-08:00</published><updated>2011-04-01T23:01:17.126-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ex02. 頻率計數"/><title type='text'>Ex02. 頻率計數</title><content type='html'>(1)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for ( i =&amp;nbsp;0 ; i &amp;lt; n ; i ++ )&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n+1&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (&amp;nbsp;j =&amp;nbsp;0 ;&amp;nbsp;j &amp;lt; n ; j ++ )&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n(n+1)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (&amp;nbsp;k =&amp;nbsp;0 ;&amp;nbsp;k &amp;lt; n ; k ++ )&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;sup&gt;2&lt;/sup&gt;(n+1)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a = a + 1 ;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;sup&gt;3&lt;/sup&gt;&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 頻率計數：&lt;span style=&quot;color: black; font-size: x-small;&quot;&gt;2n&lt;sup&gt;3&lt;/sup&gt;+2n&lt;sup&gt;2&lt;/sup&gt;+2n+1 &lt;/span&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;color: black;&quot;&gt;&lt;sup&gt;&lt;/sup&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
(2)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; i = 1 ;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; while ( i &amp;lt;= n )&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n+1&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; a = a + 1 ;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; i ++ ;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 頻率計數： &lt;span style=&quot;color: black; font-size: x-small;&quot;&gt;3n+2&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/8791793347145699039/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/02/ex02.html#comment-form' title='3 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8791793347145699039'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/8791793347145699039'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/02/ex02.html' title='Ex02. 頻率計數'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-7856216689322157654</id><published>2011-02-26T22:32:00.001-08:00</published><updated>2011-03-26T21:32:04.698-07:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Ex01. 迴圈"/><title type='text'>Ex01. 迴圈</title><content type='html'>&lt;div style=&quot;direction: ltr; language: zh-TW; margin-bottom: 0pt; margin-left: 0.35in; margin-top: 7pt; mso-line-break-override: none; punctuation-wrap: hanging; text-align: left; text-indent: -0.35in; unicode-bidi: embed; vertical-align: baseline;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;span style=&quot;color: #dd8047; font-family: Wingdings; mso-color-index: 5; mso-special-format: bullet;&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;h3 class=&quot;post-title entry-title&quot;&gt;&lt;a href=&quot;http://ds32999025.blogspot.com/2011/03/ex01.html&quot;&gt;&lt;span style=&quot;color: white; font-family: Trebuchet MS; font-size: large;&quot;&gt;EX.01 迴圈&lt;/span&gt;&lt;/a&gt; &lt;/h3&gt;&lt;div class=&quot;post-header&quot;&gt;&lt;div class=&quot;post-header-line-1&quot;&gt;&lt;/div&gt;&lt;/div&gt;&lt;div class=&quot;post-body entry-content&quot; id=&quot;post-body-5912227844427779393&quot;&gt;&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;EX.01 迴圈 &lt;br /&gt;
請說明&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;遞迴是什麼? &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANS:一個問題的內涵是由本身所定義的話，稱之為遞迴。&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 遞迴函數是由上而下分析方法的一種特殊的情況，因為子問題本身和原來問題擁有相同的特性，只是範圍改變，範圍逐漸縮小到一個終止條件。&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;遞迴擁有哪些特性? &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANS:1.函數在每次呼叫時,都可以使問題範圍逐漸縮小。&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2.函數需要擁有一個終止條件,以便結束遞迴函數的執行,否遞迴函&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;&amp;nbsp;數並不會結束,而是持續的呼叫自己，類似無窮迴圈。&lt;br /&gt;
遞迴分為哪兩種? &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ANS:1.直接遞迴&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 遞迴函數是在遞迴函數本身的程式碼進行呼叫&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 也就是自己呼叫自己,稱為直接遞迴,例如:&lt;br /&gt;
Void a()&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; A();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp; }&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: black; font-family: Times New Roman; font-size: small;&quot;&gt;&lt;br /&gt;
2.間接遞迴&lt;br /&gt;
&lt;br /&gt;
至少需要2個函數A() 和 B(),在函數A()的程式碼呼叫函數B();&lt;br /&gt;
函數B()的程式碼呼叫函數A(),此情況的遞迴呼叫稱為間接遞迴&lt;br /&gt;
例如:&lt;br /&gt;
Void A()&lt;br /&gt;
&amp;nbsp;&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; B();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp;&amp;nbsp; }&lt;br /&gt;
Void B()&lt;br /&gt;
&amp;nbsp; {&lt;br /&gt;
&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp;&amp;nbsp; A()&lt;br /&gt;
&amp;nbsp;&amp;nbsp; …&lt;br /&gt;
&amp;nbsp; }&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/7856216689322157654/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/02/ex01.html#comment-form' title='2 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7856216689322157654'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7856216689322157654'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/02/ex01.html' title='Ex01. 迴圈'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6329674406490224512.post-7529506975103540201</id><published>2011-02-19T19:41:00.000-08:00</published><updated>2011-02-25T23:10:13.633-08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="課程建議"/><title type='text'>資料結構 學習上的期望與建議</title><content type='html'>&lt;div style=&quot;text-align: left;&quot;&gt;&lt;b style=&quot;mso-bidi-font-weight: normal;&quot;&gt;&lt;span lang=&quot;EN-US&quot; style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: 新細明體;&quot;&gt;&lt;span style=&quot;mso-list: Ignore;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;1.&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;b style=&quot;mso-bidi-font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;個人對於資訊相關課程之學習經驗與問題分析．&lt;span lang=&quot;EN-US&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt 18pt; mso-layout-grid-align: none; mso-para-margin-left: 1.5gd; tab-stops: -9.0pt;&quot;&gt;&lt;span lang=&quot;EN-US&quot; style=&quot;color: #0f243e; font-family: &amp;quot;Times New Roman&amp;quot;, &amp;quot;serif&amp;quot;; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;(Ex.&lt;/span&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;曾學習過之&lt;/span&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-ascii-font-family: &amp;quot;Times New Roman&amp;quot;; mso-bidi-font-family: Arial; mso-hansi-font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;相關&lt;/span&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;電腦文書處理、程式語言、網路等；較有心得及較無心得之科目，請分析一下原因？） &lt;span lang=&quot;EN-US&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt 18pt; mso-layout-grid-align: none; tab-stops: list 36.0pt left 353.25pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt 18pt; mso-layout-grid-align: none; tab-stops: list 36.0pt left 353.25pt;&quot;&gt;高職唸的是商業類Word、Excel、PowerPoint都懂一些基本的&lt;br /&gt;
較有心得的科目是進專才接觸到的c++&lt;br /&gt;
較無心得的科目應該是沒有&lt;br /&gt;
因為我覺得資訊類的理解很重要&lt;br /&gt;
也是要花時間練習看書和上課注意聽&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt 18pt; mso-layout-grid-align: none; tab-stops: list 36.0pt left 353.25pt;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt 18pt; mso-layout-grid-align: none; tab-stops: list 36.0pt left 353.25pt;&quot;&gt;&lt;b style=&quot;mso-bidi-font-weight: normal;&quot;&gt;&lt;span lang=&quot;EN-US&quot; style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: 新細明體;&quot;&gt;&lt;span style=&quot;mso-list: Ignore;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;2.&lt;/span&gt;&lt;span style=&quot;font-family: &amp;quot;Times New Roman&amp;quot;;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;b style=&quot;mso-bidi-font-weight: normal;&quot;&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;個人對本課程學習上的想法、期望、與建議．&lt;span lang=&quot;EN-US&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/b&gt;&lt;/div&gt;&lt;div class=&quot;MsoNormal&quot; style=&quot;layout-grid-mode: char; margin: 0cm 0cm 0pt; mso-char-indent-count: 1.0; mso-layout-grid-align: none; tab-stops: list 36.0pt left 353.25pt; text-indent: 16pt;&quot;&gt;&lt;span style=&quot;color: #0f243e; font-size: 16pt; mso-bidi-font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;（&lt;span lang=&quot;EN-US&quot;&gt;Ex.&lt;/span&gt;如上課方式、教材內容等）&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: #0f243e; mso-bidi-font-family: Arial;&quot;&gt;&lt;span style=&quot;font-family: 新細明體;&quot;&gt;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;font-size: small;&quot;&gt;上課能像c++的課一樣&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; 多一點實際操作機會&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; 做中學我覺得比較快能理解&lt;/span&gt;&lt;/span&gt;&lt;span lang=&quot;EN-US&quot;&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://ds32999007.blogspot.com/feeds/7529506975103540201/comments/default' title='張貼留言'/><link rel='replies' type='text/html' href='http://ds32999007.blogspot.com/2011/02/blog-post.html#comment-form' title='1 個意見'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7529506975103540201'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6329674406490224512/posts/default/7529506975103540201'/><link rel='alternate' type='text/html' href='http://ds32999007.blogspot.com/2011/02/blog-post.html' title='資料結構 學習上的期望與建議'/><author><name>小梁</name><uri>http://www.blogger.com/profile/10763649252168674316</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry></feed>