<?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-2891501055677273230</id><updated>2024-09-22T10:10:54.953+08:00</updated><category term="程式解題"/><category term="高中生程式解題系統"/><category term="學習"/><category term="雜知識"/><category term="C"/><category term="Blogger"/><category term="Linux"/><category term="心得感想"/><category term="未分類"/><category term="生活"/><category term="超連結"/><category term="綠色軟體"/><category term="Android"/><category term="網誌"/><title type='text'>Blogger</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://rlong1106.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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>100</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-6374062003521122719</id><published>2011-01-15T12:37:00.002+08:00</published><updated>2011-01-15T12:37:34.083+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d461: 班際籃球賽</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d461&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt; &lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
using namespace std;
int main() {
    int n ;
    while(cin &amp;gt;&amp;gt; n)
    {
        cout &amp;lt;&amp;lt; n-1 &amp;lt;&amp;lt; endl ;
    }
}&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題學弟說很簡單... ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;我也不疑有它的猜他是n-1的公式 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;結果遽然猜對了XD...&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/6374062003521122719'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/6374062003521122719'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/d461.html' title='高中 d461: 班際籃球賽'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-7097811266386378414</id><published>2011-01-14T15:58:00.003+08:00</published><updated>2011-01-14T16:32:26.606+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Blogger"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>Blogger 下拉式連結選單</title><content type='html'>下拉式連結選單(開新視窗)&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; font-family: Arial, Tahoma, Helvetica, FreeSans, sans-serif; font-size: 13px; line-height: 21px;&quot;&gt;&lt;select onchange=&quot;window.open(this.options[this.selectedIndex].value)&quot;&gt;&lt;option value=&quot;&quot;&gt;==展示用==&lt;/option&gt;&lt;option value=&quot;http://google.com.tw&quot;&gt;Google&lt;/option&gt;&lt;option value=&quot;http://tw.yahoo.com&quot;&gt;yahoo&lt;/option&gt;&lt;/select&gt;&lt;/span&gt;&lt;br /&gt;
下拉式連結選單(原視窗)&lt;br /&gt;
&lt;select onchange=&quot;location.href=this.options[this.selectedIndex].value;&quot;&gt; &lt;option value=&quot;&quot;&gt;==展示用==&lt;/option&gt;&lt;option value=&quot;http://google.com.tw&quot;&gt;Google&lt;/option&gt;&lt;option value=&quot;http://tw.yahoo.com&quot;&gt;yahoo&lt;/option&gt;&lt;/select&gt;&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
下拉式連結選單(開新視窗)&lt;br /&gt;
&lt;pre class=&quot;prettyprint&quot;&gt;&amp;lt;select onchange=&quot;window.open(this.options[this.selectedIndex].value)&quot;&amp;gt;
&amp;lt;option value=&quot;&quot;&amp;gt;請填入方塊名字&amp;lt;/option&amp;gt;
&amp;lt;option value=&quot;連結網址&quot;&amp;gt;網站名稱&amp;lt;/option&amp;gt;
&amp;lt;/select&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
下拉式連結選單(原視窗)&lt;br /&gt;
&lt;pre class=&quot;prettyprint&quot;&gt;&amp;lt;select onchange=&quot;location.href=this.options[this.selectedIndex].value;&quot;&amp;gt;
&amp;lt;option value=&quot;&quot;&amp;gt;請填入方塊名字&amp;lt;/option&amp;gt;
&amp;lt;option value=&quot;連結網址&quot;&amp;gt;網站名稱&amp;lt;/option&amp;gt;
&amp;lt;/select&amp;gt;
&lt;/pre&gt;&lt;br /&gt;
參考資料&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&lt;a href=&quot;http://catherine98.blogspot.com/2009/02/blog-post_3489.html&quot;&gt;http://catherine98.blogspot.com/2009/02/blog-post_3489.html&lt;/a&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/7097811266386378414'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/7097811266386378414'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/blogger_14.html' title='Blogger 下拉式連結選單'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-1681891720111243923</id><published>2011-01-13T00:31:00.006+08:00</published><updated>2011-01-13T00:41:24.702+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>d018: 字串讀取練習</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d018&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;以下是小弟程式碼 ,&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
#include&amp;lt;math.h&amp;gt;
using namespace std;
int main() {
    string str ;
    while(getline(cin,str))
    {
        int no = 0 , status = 0 ;
        double oddSum = 0 , evenSum = 0 , temp = 0 , pointCount = 0 ;
        bool negative = false , point = false ;
        for(int i = 0 ; i &amp;lt;= str.length() ; i++)
        {
            if(status==0) // 取 no
            {
                if(str[i]!=&#39;:&#39;)
                    no = no * 10 + (int)(str[i]-48) ;
                else
                    status = 1 ;
            }
            else if(status==1) // 分析 值 
            {
                if(str[i]==&#39;-&#39;)
                {
                    negative = true ;
                    i++ ;
                }
                if(str[i]==&#39; &#39; || i==str.length()) // 分析是否加入總和 
                {
                    if((no%2)==0) // 偶數 
                    {
                        if(negative==false)
                            evenSum += temp ;
                        else 
                            evenSum -= temp ;
                    }
                    else
                    {
                        if(negative==false)
                            oddSum += temp ;
                        else 
                            oddSum -= temp ;
                    }
                    // Init
                    no = 0 ;
                    temp = 0 ;
                    pointCount = 0 ;
                    status = 0 ;
                    negative = false ;
                    point = false ;
                }
                else if(str[i]!=&#39;.&#39; &amp;amp;&amp;amp; point!=true)
                {
                    temp = temp * 10 + (int)(str[i]-48) ;
                }
                else
                {
                    if(point==false) // 判斷是否小數第一位
                    {
                        i++;
                    }
                    pointCount++;
                    temp = temp + ((str[i]-48))/pow (10,pointCount) ;
                    point = true ;
                }
            }
        }
        cout &amp;lt;&amp;lt; oddSum - evenSum &amp;lt;&amp;lt; endl ;
    }
}
&lt;/pre&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;以下是別人寫的 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;相當的短 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;值得學習阿(哭哭) ,&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
#include&amp;lt;algorithm&amp;gt;
using namespace std;
const int MAX=3000;
float arr[MAX];
int main() {
    char ch[MAX];
    char* ptr;
    while(gets(ch))
    {
        int c=0;
        float odd=0,even=0;
        ptr=strtok(ch,&quot;: &quot;);
        while(ptr!=NULL)
        {
            arr[c++]=atof(ptr);
            ptr=strtok(NULL,&quot;: &quot;);
        }
        for(int i=0 ; i &amp;lt; c ; i+=2)
        {
            if(((int)arr[i])%2)
                odd+=arr[i+1];
            else
                even+=arr[i+1];
        }
        cout &amp;lt;&amp;lt; odd - even &amp;lt;&amp;lt; endl;
        memset(arr,0.0,MAX);
    }
    return 0;
}
&lt;/pre&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題有幾個重點提示 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;小數可能不只一位&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt; ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;且輸入的值可能有&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;負數&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt; ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;大致上就這些要注意 :P ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;P.S 多使用函式庫吧!! 高手寫的好短阿 &amp;gt;_&amp;lt; &lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;早知也使用atof了&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/1681891720111243923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/1681891720111243923'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/d018.html' title='d018: 字串讀取練習'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-489036790346679083</id><published>2011-01-09T12:39:00.020+08:00</published><updated>2011-01-11T23:10:41.422+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Blogger"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>Blogger 文章加密</title><content type='html'>&lt;a href=&quot;javascript:Decrypt_text(&#39;unique_name&#39;);&quot;&gt;點擊此處解開火星文(密碼:test)&lt;/a&gt;&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;div id=&quot;unique_name&quot;&gt;BRXABMjPpRIy/XnqWP+5AdrMide+TtlDncneBAv+fQGR32hw\n2tQnFbrCVV9eyhBxAhKmTLviPxPN2OOG1CQPfw==&lt;/div&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;首先要再Blogger嵌入加入所需的Javascript ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;並將程式碼加入加入到Blogger的之上 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;程式碼與作法如下 ,&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;prettyprint&quot;&gt;&amp;lt;script language=&#39;JavaScript&#39; src=&#39;http://vincentcheung.googlepages.com/blogjscrypt.js&#39;&amp;gt;
&amp;lt;/script&amp;gt;&lt;/pre&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrWLeP_qqZcZ31y7zIjbKQDW0gLMgNWpkvhXwhouBW_QnyIERKmAEAyDyHasjRUP0F_Br5DyVs-9U2tD1ADoEPFCZ7E6oYmpk6tpbIoD1_dgBQgrDhaaQ2Xn0Zdte9sT7MGkldNxZDr1kB/s1600/1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;377&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrWLeP_qqZcZ31y7zIjbKQDW0gLMgNWpkvhXwhouBW_QnyIERKmAEAyDyHasjRUP0F_Br5DyVs-9U2tD1ADoEPFCZ7E6oYmpk6tpbIoD1_dgBQgrDhaaQ2Xn0Zdte9sT7MGkldNxZDr1kB/s400/1.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;之後再透過網站&amp;nbsp;&lt;/span&gt;&lt;a href=&quot;http://www.vincentcheung.ca/jsencryption/old.html&quot;&gt;http://www.vincentcheung.ca/jsencryption/old.html&lt;/a&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;來做火星文加密 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;我們只須在網站中的key欄位輸入密碼 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;Plain Text輸入內文(html語法可,html可&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;嵌入圖片&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;) ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;之後再點擊Encrypt的Button就會產生火星文至Cipher Text中 ,&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: ledt;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgsorzGJ8goVaLDaCtuuXRsicWOe164Wr9C6svtpk_B9Htx6hwLIdVfGu8jh1rMX7ziAkqz8Cz5dcZxs4XDVqtJS4XnmNmGMmwDORyZ5eQIDMCuv8sK86GBY_ZxlnIdT4jprfGwHYheHewn/s1600/1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;271&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgsorzGJ8goVaLDaCtuuXRsicWOe164Wr9C6svtpk_B9Htx6hwLIdVfGu8jh1rMX7ziAkqz8Cz5dcZxs4XDVqtJS4XnmNmGMmwDORyZ5eQIDMCuv8sK86GBY_ZxlnIdT4jprfGwHYheHewn/s400/1.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;之後只需再發文章時 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;在文章中&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;嵌入火星文以及他的用法即可 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;他的用法如下 ,&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;prettyprint&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333;&quot;&gt;&amp;lt;a href=&quot;javascript:Decrypt_text(&#39;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;unique_name&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333;&quot;&gt;&#39;);&quot;&amp;gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;火星文超連結+提示字語打這&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333;&quot;&gt;&amp;lt;/a&amp;gt;
&amp;lt;div id=&quot;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;unique_name&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333;&quot;&gt;&quot;&amp;gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: lime;&quot;&gt;前面步驟的火星文貼這唷!!&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: #333333;&quot;&gt;&amp;lt;/div&amp;gt;&lt;/span&gt;
&lt;/pre&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;為了怕大家不懂我在po張圖:P&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;發文時步驟如下即可&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjic0wXA7IHkVIegl6I_uw9a4lqP8tQ_1J_Kjmb1-umqfD0xFyBE2z3IFiss8cvPTPcZte3u0pWEp4UDd62f__I-vyF_odftxVYdUNOml7sSMPuHKo8zRkJguSEq9WVzoGjRVj81rPH8t1U/s1600/1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;108&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjic0wXA7IHkVIegl6I_uw9a4lqP8tQ_1J_Kjmb1-umqfD0xFyBE2z3IFiss8cvPTPcZte3u0pWEp4UDd62f__I-vyF_odftxVYdUNOml7sSMPuHKo8zRkJguSEq9WVzoGjRVj81rPH8t1U/s400/1.jpg&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;P.S 剛剛上面的&amp;nbsp;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red; font-family: &#39;Courier New&#39;; font-size: 13px; line-height: 15px; white-space: pre;&quot;&gt;unique_name&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;一個顯示頁面只能出現一次 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;若要顯示兩次以上的火星文建議改成流水號 ex: a01,a02... ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;以免發生錯誤^_^&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;參考資料:&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;/span&gt;&lt;a href=&quot;http://chenkaie.blogspot.com/2007/03/javascript-encrypt-your-private-blog.html&quot;&gt;http://chenkaie.blogspot.com/2007/03/javascript-encrypt-your-private-blog.html&lt;/a&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/489036790346679083'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/489036790346679083'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/blogger_09.html' title='Blogger 文章加密'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEhrWLeP_qqZcZ31y7zIjbKQDW0gLMgNWpkvhXwhouBW_QnyIERKmAEAyDyHasjRUP0F_Br5DyVs-9U2tD1ADoEPFCZ7E6oYmpk6tpbIoD1_dgBQgrDhaaQ2Xn0Zdte9sT7MGkldNxZDr1kB/s72-c/1.jpg" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2350550818111198085</id><published>2011-01-08T23:25:00.008+08:00</published><updated>2011-01-09T08:10:50.058+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Blogger"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>Blogger置頂文章(簡單的)</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh6OrAKoTUdlE8JhgjIdjY-PdgWGZ8Vnh_X-p50V_GXeYr3HxwbH5DIx4MJO_USqgjJSLbbt0k1fuXlFjCaJP7WpF6iIiApWjqTFFd10lhp0ottSamsi-HA-RfvLM25UZV3IJd7FwSjgNcH/s1600/4.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;271&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh6OrAKoTUdlE8JhgjIdjY-PdgWGZ8Vnh_X-p50V_GXeYr3HxwbH5DIx4MJO_USqgjJSLbbt0k1fuXlFjCaJP7WpF6iIiApWjqTFFd10lhp0ottSamsi-HA-RfvLM25UZV3IJd7FwSjgNcH/s400/4.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;製作一個置頂文章 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;首先點選設計自己的Blogger ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;然後新增小工具 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;要新增的小工具如下圖 ,&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUgooysJ0PgrQgUTPHnWvgHTdj-Rqpmrk87s7kcG7ErVrcMuP0xPOsKHfFboILLLuf68jSLRtvG0KjR36gs_eaCBa8ws3qbOT3uc3U2HgWleDXgY3WLLNUG8I4_7lmxwAOPd52Jac22x-D/s1600/1.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em; text-align: left;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;222&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjUgooysJ0PgrQgUTPHnWvgHTdj-Rqpmrk87s7kcG7ErVrcMuP0xPOsKHfFboILLLuf68jSLRtvG0KjR36gs_eaCBa8ws3qbOT3uc3U2HgWleDXgY3WLLNUG8I4_7lmxwAOPd52Jac22x-D/s320/1.JPG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;之後只需輸入一些字之後即可 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;做法如下圖 ,&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisxwin12YG0UzWRAsW73xPxVlD1JOWyzKiUyESDbce_0q7nik6gYwf6eSz6A6mKnVhwub8gv073N_ho-CEUKZLS6-k3izZX3fdSIJ56g7QKTSLYVlRoh6rPmD_gSrVYRnKJ8DhBHdRAErO/s1600/2.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;360&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEisxwin12YG0UzWRAsW73xPxVlD1JOWyzKiUyESDbce_0q7nik6gYwf6eSz6A6mKnVhwub8gv073N_ho-CEUKZLS6-k3izZX3fdSIJ56g7QKTSLYVlRoh6rPmD_gSrVYRnKJ8DhBHdRAErO/s400/2.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;最後再移至網誌文章之上即可 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;做法如下圖 ,&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4oofPV-BU-dCscQx7HJSNJUo8EejbzXvbPbCzCVeZEBBk1ySvVUUBT35o6PUZ4HjxsTNEcFir9Pma6bd3bM1pRCwQ7GBInwxNJIA9IlgDUOBnXlI_Nhyphenhyphen3OTJF-GwvDcOQFK6o4Abh3gL/s1600/3.JPG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;222&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgy4oofPV-BU-dCscQx7HJSNJUo8EejbzXvbPbCzCVeZEBBk1ySvVUUBT35o6PUZ4HjxsTNEcFir9Pma6bd3bM1pRCwQ7GBInwxNJIA9IlgDUOBnXlI_Nhyphenhyphen3OTJF-GwvDcOQFK6o4Abh3gL/s400/3.JPG&quot; width=&quot;400&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;完成圖如開頭:P&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2350550818111198085'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2350550818111198085'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/blogger_08.html' title='Blogger置頂文章(簡單的)'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEh6OrAKoTUdlE8JhgjIdjY-PdgWGZ8Vnh_X-p50V_GXeYr3HxwbH5DIx4MJO_USqgjJSLbbt0k1fuXlFjCaJP7WpF6iIiApWjqTFFd10lhp0ottSamsi-HA-RfvLM25UZV3IJd7FwSjgNcH/s72-c/4.JPG" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-86579754386243453</id><published>2011-01-08T10:30:00.002+08:00</published><updated>2011-01-09T08:08:14.713+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Blogger"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>Blogger 文章搜尋</title><content type='html'>&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/AVvXsEiRTHvcNMSufu0XdMqL-V_Gc0KM-i59NuYYhKznLFl8rgdUFVVjZg69uY7YujjyH2w9lgUrEszIg8H4bTkKcOkAYL8bkkgwbsl_5t_9O4xBnGlcehk0sRbKtfiFp-J6Yx0wOq7z9MsVb5kR/s1600/1.bmp&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; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiRTHvcNMSufu0XdMqL-V_Gc0KM-i59NuYYhKznLFl8rgdUFVVjZg69uY7YujjyH2w9lgUrEszIg8H4bTkKcOkAYL8bkkgwbsl_5t_9O4xBnGlcehk0sRbKtfiFp-J6Yx0wOq7z9MsVb5kR/s1600/1.bmp&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;其實Google Blogger本身有提供此網誌文章搜尋 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;不必自己特意去新增一個 (雖然小弟也新增過) ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;只要如上圖打上關鍵字&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;就可以找到自己想在此網誌的文章^_^&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/86579754386243453'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/86579754386243453'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/blogger.html' title='Blogger 文章搜尋'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEiRTHvcNMSufu0XdMqL-V_Gc0KM-i59NuYYhKznLFl8rgdUFVVjZg69uY7YujjyH2w9lgUrEszIg8H4bTkKcOkAYL8bkkgwbsl_5t_9O4xBnGlcehk0sRbKtfiFp-J6Yx0wOq7z9MsVb5kR/s72-c/1.bmp" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-8609087528578096923</id><published>2011-01-08T10:19:00.012+08:00</published><updated>2011-01-10T19:22:54.735+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Blogger"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>Google日曆嵌入在Blogger</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;首先當然要先有Google帳號 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;並且開啟Google日曆 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;過來就是重要時刻四步驟 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;Step 1. 進入Google日曆後如下圖點選設定&lt;/span&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;clear: left; color: blue; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhfFxx5gIfYMwYJG4pfZdCu_gh7iYInP-QhoByBSdf7IFvHkJABVfsgSFXagqZVv_PNaoCO0AjXdCNGCyr-bLjrgj32R0NOJP3wA6IAZiLtKuN4arDG-cnNR-OP-n1HR5luo3rrPU4elbL9/s1600/1.bmp&quot; /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;Step 2. 如下圖 , 彈至出來的視窗點選共用此日曆&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;clear: left; color: blue; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;204&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEizg2nfGMFVQjrvXy0LxDVVMFCOIgtvYePbQ29Zg3C3SRujDZhs0r5-CHLX8fxqIJ52P95ogDV5u7UpIgtotYXaNebDeLpZ5dHMbkM2z5E7Lq332_ES6LRXr-i5Js1LQsf7mimFuqmab9LX/s400/2.bmp&quot; width=&quot;400&quot; /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;Step 3. 將公開此日曆打個勾&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;clear: left; color: blue; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;315&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhi5WfYTTgCNGXecHTzcrnbc6PFrnnujcSOB3azObb4gNbfdlInu2lmXtEQee-5icw3MA8iQvnY9qqnPWOK7CYhwMsgsrj6zz1rALxAigntwwb6lSyGNenY_VCSpiDEM2W7PCdG_c7P9H2I/s400/3.bmp&quot; width=&quot;400&quot; /&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;Step 4. 點選左上切換至日曆詳細資料 , 並往下找到code的部分&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;clear: left; color: blue; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrWLeP_qqZcZ31y7zIjbKQDW0gLMgNWpkvhXwhouBW_QnyIERKmAEAyDyHasjRUP0F_Br5DyVs-9U2tD1ADoEPFCZ7E6oYmpk6tpbIoD1_dgBQgrDhaaQ2Xn0Zdte9sT7MGkldNxZDr1kB/s1600/1.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhrWLeP_qqZcZ31y7zIjbKQDW0gLMgNWpkvhXwhouBW_QnyIERKmAEAyDyHasjRUP0F_Br5DyVs-9U2tD1ADoEPFCZ7E6oYmpk6tpbIoD1_dgBQgrDhaaQ2Xn0Zdte9sT7MGkldNxZDr1kB/s1600/1.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;呼....&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;最後大家再把它放入Blogger的HTML/JavaScript ,&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這樣就可以在Blogger看到日曆了 ,&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;大家也都可以喔^_^&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/8609087528578096923'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/8609087528578096923'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/google.html' title='Google日曆嵌入在Blogger'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEhfFxx5gIfYMwYJG4pfZdCu_gh7iYInP-QhoByBSdf7IFvHkJABVfsgSFXagqZVv_PNaoCO0AjXdCNGCyr-bLjrgj32R0NOJP3wA6IAZiLtKuN4arDG-cnNR-OP-n1HR5luo3rrPU4elbL9/s72-c/1.bmp" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-3556748670827025683</id><published>2011-01-04T06:40:00.002+08:00</published><updated>2011-01-04T06:41:32.255+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="網誌"/><title type='text'>病</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;小弟在期末考周破病，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這是多麼不信的事，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但還有更不信的事，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;就是破病遽然還要給同學吸趴，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;吸趴的同學根本是7原罪的謎樣生物體，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;叫小弟假日拖者38度半的脆弱身體幫他做實驗，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;一做就是6個小時，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;再叫小弟花2小時做ppt，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這還有天良嗎?&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;期末考都浪費在這位同學身上了，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;難怪這位同學的某些科目期末報告被同組踢掉導致零分，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;沒有&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: x-large;&quot;&gt;愛&lt;/span&gt;阿!&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;多愛自己周圍的人多一點!&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 2px; -webkit-border-vertical-spacing: 2px; border-collapse: collapse; font-family: Verdana, Helvetica, Arial, Lucida, sans-serif; line-height: 21px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;P.S 7原罪 貪吃、貪婪、懶惰、忌妒、憤怒、傲慢、色慾&lt;/span&gt;&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3556748670827025683'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3556748670827025683'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2011/01/blog-post.html' title='病'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-3248028089049909081</id><published>2010-12-30T08:26:00.007+08:00</published><updated>2010-12-30T22:52:14.678+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d564. 整數編號輸出</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;div style=&quot;margin: 0px;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d564&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include &amp;lt;iostream&amp;gt;
using namespace std;

main() {
&amp;nbsp;&amp;nbsp; &amp;nbsp; int n ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; string s ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; while(cin &amp;gt;&amp;gt; s &amp;gt;&amp;gt; n)
&amp;nbsp;&amp;nbsp; &amp;nbsp; {
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if(n&amp;gt;=0 &amp;amp;&amp;amp; n&amp;lt;=2147483647)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if(s==&quot;C&quot;)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &quot;\&quot;&quot; &amp;lt;&amp;lt; s &amp;lt;&amp;lt; &quot;\&quot; can use printf(\&quot;%d\&quot;,n); to show integer like &quot; &amp;lt;&amp;lt; n &amp;lt;&amp;lt; &quot;.&quot; &amp;lt;&amp;lt; endl ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (s==&quot;C++&quot;)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &quot;\&quot;&quot; &amp;lt;&amp;lt; s &amp;lt;&amp;lt; &quot;\&quot; can use cout&amp;lt;&lt;n; &quot;.&quot;=&quot;&quot; &quot;=&quot;&quot; ;&amp;nbsp;&lt;=&quot;&quot; &lt;&lt;=&quot;&quot; endl=&quot;&quot; integer=&quot;&quot; like=&quot;&quot; n=&quot;&quot; p=&quot;&quot; show=&quot;&quot; to=&quot;&quot;&gt;&lt;/n;&gt;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (s==&quot;Java&quot;)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &quot;\&quot;&quot; &amp;lt;&amp;lt; s &amp;lt;&amp;lt; &quot;\&quot; can use System.out.print(n); to show integer like &quot; &amp;lt;&amp;lt; n &amp;lt;&amp;lt; &quot;.&quot; &amp;lt;&amp;lt; endl ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (s==&quot;Pascal&quot;)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &quot;\&quot;&quot; &amp;lt;&amp;lt; s &amp;lt;&amp;lt; &quot;\&quot; can use Write(n); to show integer like &quot; &amp;lt;&amp;lt; n &amp;lt;&amp;lt; &quot;.&quot; &amp;lt;&amp;lt; endl ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (s==&quot;Basic&quot;)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &quot;\&quot;&quot; &amp;lt;&amp;lt; s &amp;lt;&amp;lt; &quot;\&quot; can use Print n to show integer like &quot; &amp;lt;&amp;lt; n &amp;lt;&amp;lt; &quot;.&quot; &amp;lt;&amp;lt; endl ; 
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; else
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; break ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&amp;nbsp;&amp;nbsp; &amp;nbsp; }
}
&lt;/pre&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3248028089049909081'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3248028089049909081'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/d564.html' title='高中 d564. 整數編號輸出'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-5103511330921053617</id><published>2010-12-30T08:20:00.002+08:00</published><updated>2010-12-30T08:35:27.744+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>原創題目(147)</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
d036 d075 d085 d092 d118 d125 d137 d155 d156 d157 d167&lt;br /&gt;
d173 d177 d180 d199 d201 d202 d203 d209 d213 d214 d218&lt;br /&gt;
d228 d236 d237 d238 d239 d243 d246 d262 d266 d276 d280&lt;br /&gt;
d283 d284 d288 d289 d290 d291 d294 d295 d296 d297 d304&lt;br /&gt;
d308 d309 d311 d312 d313 d314 d315 d316 d323 d328 d330&lt;br /&gt;
d334 d336 d337 d353 d359 d360 d363 d367 d378 d400 d401&lt;br /&gt;
d402 d406 d407 d408 d411 d416 d422 d425 d427 d434 d444&lt;br /&gt;
d445 d446 d448 d456 d458 d459 d463 d472 d476 d477 d479&lt;br /&gt;
d480 d486 d487 d488 d512 d533 d543 d549 d552 &lt;a href=&quot;http://rlong1106.blogspot.com/2010/12/d564.html&quot;&gt;d564&lt;/a&gt; d572&lt;br /&gt;
d577 d578 d579 d580 d581 d614 d615 d618 d621 d624 d627&lt;br /&gt;
d632 d633 d640 d647 d655 d668 d688 d692 d704 d708 d712&lt;br /&gt;
d713 d716 d717 d718 d730 d734 d735 d741 d763 d804 d806&lt;br /&gt;
d807 d808 d809 &lt;a href=&quot;http://rlong1106.blogspot.com/2010/12/d810.html&quot;&gt;d810&lt;/a&gt; d815 d816 d817 d825 d826 d828 d830&lt;br /&gt;
d831 d832 d885 d909</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5103511330921053617'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5103511330921053617'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/147.html' title='原創題目(147)'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2988717893158181614</id><published>2010-12-30T00:41:00.000+08:00</published><updated>2010-12-30T00:41:41.849+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d491: 我也愛偶數 (swap 版)</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d491&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
using namespace std;

int main()
{
    int a , b ;
    while(cin &gt;&gt; a &gt;&gt; b)
    {
        if( a &gt; b) // swap
        {
            int temp ;
            temp = a ;
            a = b ;
            b = temp ;
        }
        if(a%2 != 0) // 判斷 a 值是否落在奇數 
            a += 1 ;
        if(b%2 != 0) // 判斷 b 值是否落在奇數 
            b -= 1 ;
        cout &lt;&lt; ((a+b)*((b-a)/2+1))/2 &lt;&lt; endl ; // 梯形公式 
    }
}
&lt;/pre&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2988717893158181614'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2988717893158181614'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/d491-swap.html' title='高中 d491: 我也愛偶數 (swap 版)'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-4379390869975125732</id><published>2010-12-30T00:37:00.001+08:00</published><updated>2010-12-30T00:40:33.277+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d490: 我也愛偶數</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d490&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
using namespace std;

int main()
{
    int a , b ;
    while(cin &gt;&gt; a &gt;&gt; b)
    {
        if(a%2 != 0) // 判斷 a 值是否落在奇數 
            a += 1 ;
        if(b%2 != 0) // 判斷 b 值是否落在奇數 
            b -= 1 ;
        cout &lt;&lt; ((a+b)*((b-a)/2+1))/2 &lt;&lt; endl ; // 梯形公式 
    }
}
&lt;/pre&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/4379390869975125732'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/4379390869975125732'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/d490.html' title='高中 d490: 我也愛偶數'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-5191798306343677349</id><published>2010-12-30T00:01:00.002+08:00</published><updated>2010-12-30T00:02:12.648+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="未分類"/><category scheme="http://www.blogger.com/atom/ns#" term="雜知識"/><title type='text'>一個老工程師給年輕工程師的十大忠告</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif; line-height: 27px;&quot;&gt;[1]好好規劃自己的路，不要跟著感覺走！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;根據個人的理想決策安排，絕大部分人並不指望成為什麼院士或教授，而是希望活得滋潤一些，爽一些。那麼，就需要慎重安排自己的軌跡。從哪個行業入手，逐漸對該行業深入瞭解，不要頻繁跳槽，特別是不要為了一點工資而轉移陣地，從長遠看，這點錢根本不算什麼，當你對一個行業有那麼幾年的體會，以後錢根本不是問題。頻繁地動盪不是上策，最後你對哪個行業都沒有摸透，永遠是新手！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[2]可以做技術，切不可沉湎於技術。&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;千萬不可一門心思鑽研技術！給自己很大壓力，如果你的心思全部放在這上面，那麼註定你將成為孔乙己一類的人物！適可而止為之，因為技術只不過是你今後前途的支柱之一，而且還不是最大的支柱，除非你只願意到老還是個工程師！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[3]不要去做技術高手，只去做綜合素質高手！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;在企業裏混，我們時常瞧不起某人，說他『什麼都不懂，憑啥拿那麼多錢，憑啥升官！』這是普遍的典型的工程師的迂腐之言。8051很牛嗎？人家能上去必然有他的本事，而且是你沒有的本事。你想想，老闆搞經營那麼多年，難道見識不如你這個新兵？人家或許善於管理，善於領會老闆意圖，善於部門協調等等。因此務必培養自己多方面的能力，包括管理，親和力，察言觀色能力，公關能力等，要成為綜合素質的高手，則前途無量，否則只能躲在角落看示波器！技術以外的技能才是更重要的本事！！從古到今，美國日本，一律如此！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[4]多交社會三教九流的朋友！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;不要只和工程師交往，認為有共同語言，其實更重要的是和其他類人物交往，如果你希望有朝一日當老闆或高層管理，那麼你整日面對的就是這些人。瞭解他們的經歷，思維習慣，愛好，學習他們處理問題的模式，瞭解社會各個角落的現象和問題，這是以後發展的巨大的本錢，沒有這些以後就會笨手笨腳，跌跌撞撞，遇到重重困難，交不少學費，成功的概率大大降低！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[5]知識涉獵不一定專，但一定要廣！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;多看看其他方面的書，金融，財會，進出口，稅務，法律等等，為以後做一些積累，以後的用處會更大！會少交許多學費！！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[6]抓住時機向技術管理或市場銷售方面的轉變！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;要想有前途就不能一直搞開發，適當時候要轉變為管理或銷售，前途會更大，以前搞技術也沒有白搞，以後還用得著。搞管理可以培養自己的領導能力，搞銷售可以培養自己的市場概念和思維，同時為自己以後發展積累龐大的人脈！應該說這才是前途的真正支柱！！！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[7]逐漸克服自己的心裏弱點和性格缺陷！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;多疑，敏感，猶豫不決，膽怯，多慮，這些工程師普遍存在的性格弱點必須改變！很難嗎？只在床上想一想當然不可能，去幫朋友守一個月地攤，包准有效果，去實踐，而不要只想！不克服這些缺點，一切不可能，甚至連項目經理都當不好--儘管你可能技術不錯！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[8]工作的同時要為以後做準備！建立自己的工作環境！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;及早為自己配置一個工作環境，裝備電腦，示波器（可以買個二手的），模擬器，編程器等，業餘可以接點活，一方面接觸市場，培養市場感覺，同時也積累資金，更重要的是準備自己的產品，咱搞技術的沒有錢，只有技術，技術的代表不是學歷和證書，而是產品，拿出像樣的產品，就可技術轉讓或與人合作搞企業！先把東西準備好，等待機會，否則，有了機會也抓不住！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[9]要學會善於推銷自己！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;不僅要能幹，還要能說，能寫，善於利用一切機會推銷自己，樹立自己的品牌形象，很必要！要創造條件讓別人瞭解自己，不然老闆怎麼知道你能幹？外面的投資人怎麼相信你？提早把自己推銷出去，機會自然會來找你！搞個個人主頁是個好注意！！特別是培養自己在行業的名氣，有了名氣，高薪機會自不在話下，更重要的是有合作的機會...&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;[10]該出手時便出手！&amp;nbsp;&lt;br style=&quot;font-family: Verdana, Arial, Helvetica, sans-serif;&quot; /&gt;永遠不可能有100%把握！！！條件差不多就要大膽去幹，去闖出自己的事業，不要猶豫，不要彷徨，幹了不一定成功，但至少為下一次衝擊積累了經驗，不幹永遠沒出息，而且要幹成必然要經歷失敗。不經歷風雨，怎麼見彩虹，沒有人能隨隨便便成功！&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://www.mobile01.com/topicdetail.php?f=37&amp;amp;t=1030&quot;&gt;資料來源&lt;/a&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5191798306343677349'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5191798306343677349'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/blog-post_30.html' title='一個老工程師給年輕工程師的十大忠告'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2221626016916386965</id><published>2010-12-29T23:41:00.005+08:00</published><updated>2011-01-09T19:34:40.857+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="超連結"/><title type='text'>雜知識</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;a href=&quot;http://rlong1106.blogspot.com/search/label/%E7%94%9F%E6%B4%BB&quot;&gt;生活&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: large;&quot;&gt;&lt;a href=&quot;http://rlong1106.blogspot.com/search/label/%E7%B6%A0%E8%89%B2%E8%BB%9F%E9%AB%94&quot;&gt;綠色軟體&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;a href=&quot;http://rlong1106.blogspot.com/search/label/%E6%9C%AA%E5%88%86%E9%A1%9E&quot;&gt;未分類&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div style=&quot;margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;&quot;&gt;&lt;span style=&quot;font-size: large;&quot;&gt;&lt;a href=&quot;http://rlong1106.blogspot.com/search/label/輕小說&quot;&gt;輕小說&lt;/a&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2221626016916386965'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2221626016916386965'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/blog-post.html' title='雜知識'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2937507117829242629</id><published>2010-12-25T11:44:00.004+08:00</published><updated>2010-12-29T17:12:22.975+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 a008: 中文大寫數字</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=a008&quot;&gt;&lt;span style=&quot;font-size: x-large;&quot;&gt;想看題目請點我&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
using namespace std ;

int main(){
    string n ;
    string number[10] = {&quot;零&quot;,&quot;壹&quot;,&quot;貳&quot;,&quot;參&quot;,&quot;肆&quot;,&quot;伍&quot;,&quot;陸&quot;,&quot;柒&quot;,&quot;捌&quot;,&quot;玖&quot;} ;
    string unit1[3] = {&quot;拾&quot;,&quot;佰&quot;,&quot;仟&quot;} ; // unit1 與 unit2 差別在於會重複出現 ex 111111 會重複出現 &quot;拾&quot;
    string unit2[2] = {&quot;萬&quot;,&quot;億&quot;} ;
    while(getline(cin,n))
    {
        int zlength ;
        for(int i=0 ; i &amp;lt; n.length() ; i++)
            if(n[n.length()-i-1]!=&#39;0&#39;)  // 由右往左找 0 的總數 ex 100 , zlength = 2
            {
                zlength=i;
                break;
            }
        for(int i=0 ; i &amp;lt; n.length() ; i++)
        {
            if(n[i] != &#39;0&#39;)
            {
                cout &amp;lt;&amp;lt; number[n[i]-48] ;
                if((n.length()-i-1)%4 != 0) // 顯示 &quot;拾&quot; &quot;佰&quot; &quot;仟&quot;  
                    cout &amp;lt;&amp;lt; unit1[((n.length()-i-1)%4)-1] ; 
            } 
            if((n.length()-i-1)%4 == 0 &amp;amp;&amp;amp; (n.length()-i-1) &amp;gt;0) // 顯示 &quot;萬&quot; &quot;億&quot;
                cout &amp;lt;&amp;lt; unit2[((n.length()-i-1)/4)-1] ; 
            if(n[i]==&#39;0&#39;&amp;amp;&amp;amp;n[i-1]!=&#39;0&#39; &amp;amp;&amp;amp; i &amp;lt; n.length()-zlength) // 避免有 壹拾萬 這一類的 
                cout &amp;lt;&amp;lt; number[0] ;
        }
        cout &amp;lt;&amp;lt; endl;
    }
}
&lt;/pre&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題小弟也解了好久 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;總是有些小錯誤 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;最後看了某位高手的程式才恍然大悟阿~&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題要注意的部分就只有 &quot;拾&quot; &quot;佰&quot; &quot;仟&quot; &quot;萬&quot; &quot;億&quot; ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;其他顯示的部分我想大家跟我一樣是不會有錯誤的,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial; white-space: normal;&quot;&gt; &lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&quot;拾&quot; &quot;佰&quot; &quot;仟&quot; 與 &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&quot;萬&quot; &quot;億&quot; 有個致命的不同點 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;就是 &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&quot;拾&quot; &quot;佰&quot; &quot;仟&quot; 會重複&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;顯示&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt; ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Arial; white-space: normal;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&quot;萬&quot; &quot;億&quot; 不會重複顯示 &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;,&lt;/span&gt;&lt;br /&gt;
另外還有要計算最後有多少個零串在一起 ,&lt;br /&gt;
就可以簡單度過這一題了 ,&lt;br /&gt;
看來小弟分析題目的能力還有一大段路要走阿~ 這題困難度2阿 !!&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2937507117829242629'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2937507117829242629'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/a008.html' title='高中 a008: 中文大寫數字'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2217261469077092987</id><published>2010-12-19T13:21:00.007+08:00</published><updated>2010-12-29T17:12:22.976+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d016. 後序運算法</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d016&quot;&gt;&lt;span style=&quot;font-size: x-large;&quot;&gt;想看題目請點我&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;iostream&amp;gt;
using namespace std ;

int operation(int temp1,int temp2,char op) ; // 計算 
int push(int temp1) ; // 放入 
int pop(int temp1) ; // 取出 

#define strLen 200 // 定義能讀取字元的數目 
char str[strLen] ;
int stack[strLen] ;
int stackLen = 0 ;
int main()
{
    while(cin.getline(str,50)) // 輸入 str 字串, 最多 strLen 個字元 (getline : 讀取整行)
    {
        int result = 0 ;
        for(int i = 0 ; i &amp;lt; strlen(str) ; i++) 
        {
            if(!isspace(str[i])) // 當 str[i] 不是空白才執行 
            { 
                if((int)str[i] &amp;gt;= 48 &amp;amp;&amp;amp; (int)str[i] &amp;lt;= 57) // 取 0~9 數字 ascii
                {
                    push(((int)str[i])-48) ;
                }
                else // 若是運算元則執行
                {
                    result = operation(pop(stackLen-1),pop(stackLen-1),str[i]) ;
                    stack[stackLen] = result ; // 處理須放入堆疊在運算的一類 ex 20 30 + 40 *  
                }
            }
            else
            {
                stackLen++ ; // 當是空白時 代表要放入下一個數字 
            }
        }
        stack[stackLen] = 0 ; //清除最後存的 result 
        cout &amp;lt;&amp;lt; result &amp;lt;&amp;lt; endl ;
    } 
}

int operation(int temp1,int temp2,char op)
{
    switch(op)
    {
        case &#39;+&#39;:
             return temp1+temp2;
        case &#39;-&#39;:
             return temp1-temp2;
        case &#39;*&#39;:
             return temp1*temp2;
        case &#39;/&#39;:
             return temp1/temp2;
        case &#39;%&#39;:
             return temp1%temp2;
    }
}

int push(int temp1) // 放入 
{
    stack[stackLen] = stack[stackLen]*10 + temp1 ;
}

int pop(int temp1) // 取出 
{ 
    int returnNumber = stack[temp1] ;
    stackLen-- ;
    stack[stackLen] = 0; //清除
    return returnNumber ;
}
&lt;/pre&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;這題大概說明一下小弟的想法 ,&lt;br /&gt;
push(((int)str[i])-48)這一段呢 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;會去做 stack[stackLen] = stack[stackLen]*10 + temp1 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;為什麼要這樣做呢 ?&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;因為電腦&lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;只會由左往右看 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;但是很不巧的左邊又是比較大的數目 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;因此每當向右移動一格時 左邊就多10倍 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;ex:&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 543&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step1 : 5&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step2 : 5 * 10 + 4 = 54&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step3 : 54 * 10 + 3 = 543&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;還有一個小弟想的小技巧 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;關於stackLen++與stackLen--的時機 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;ex:&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp; &amp;nbsp;3 5 +&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step1 : strack[0] = 3&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step2 : 遇到空白 , stackLen++&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step3 : strack[1] = 5&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step4 : 遇到空白 , stackLen++&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;step5 : strack[2] = + , &lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;在這時會去做operation(pop(stackLen-1),&lt;/span&gt;&lt;span style=&quot;color: blue;&quot;&gt;pop(stackLen-1),str[i]) , &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;這行會因為pop而stackLen--做兩次 , &lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;所以最後回傳時 strack[0] = (3+5) 的答案&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;附註：operation(pop(stackLen-1),&lt;span style=&quot;color: blue;&quot;&gt;pop(stackLen-1),str[i])&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 這行應該由左向右執行 ,&lt;/span&gt;&lt;br /&gt;
&lt;span style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 因此會先做左邊的pop(stackLen-1)&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2217261469077092987'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2217261469077092987'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/d016.html' title='高中 d016. 後序運算法'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2609182927746186917</id><published>2010-12-18T15:09:00.011+08:00</published><updated>2010-12-29T17:12:22.977+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="程式解題"/><category scheme="http://www.blogger.com/atom/ns#" term="高中生程式解題系統"/><title type='text'>高中 d810: 大朋友下樓梯</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;div style=&quot;margin: 0px;&quot;&gt;&lt;br /&gt;
&lt;/div&gt;&lt;div style=&quot;margin: 0px;&quot;&gt;&lt;span style=&quot;font-size: x-large;&quot;&gt;&lt;a href=&quot;http://zerojudge.tw/ShowProblem?problemid=d810&quot;&gt;想看題目請點我&lt;/a&gt;&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include &amp;lt;iostream&amp;gt;
using namespace std;
int answer ;
int recursive(int nowT,int k,int t);
int main() {
&amp;nbsp;&amp;nbsp; &amp;nbsp; int t,k ; // t 遊戲難度 , k 地下k樓 （0&amp;gt;k&amp;gt;-20）
&amp;nbsp;&amp;nbsp; &amp;nbsp; while(cin &amp;gt;&amp;gt; t &amp;gt;&amp;gt; k )
&amp;nbsp;&amp;nbsp; &amp;nbsp; {
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; answer = 0 ; // Init
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; recursive(t,(-k),t);
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; cout &amp;lt;&amp;lt; &amp;nbsp;answer &amp;lt;&amp;lt; endl ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; }
}

int recursive(int nowT,int k,int t) {
&amp;nbsp;&amp;nbsp; &amp;nbsp;if((k - nowT ) &amp;lt; 0)
&amp;nbsp;&amp;nbsp; &amp;nbsp;{
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;recursive((nowT-1),(k),t);
&amp;nbsp;&amp;nbsp; &amp;nbsp;}
&amp;nbsp;&amp;nbsp; &amp;nbsp;else if( k == 0)
&amp;nbsp;&amp;nbsp; &amp;nbsp;{
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;answer++ ;
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if(nowT &amp;gt; 1)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;recursive((nowT-1),(k),t);
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;else
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;return EXIT_SUCCESS ;
&amp;nbsp;&amp;nbsp; &amp;nbsp;}
&amp;nbsp;&amp;nbsp; &amp;nbsp;else
&amp;nbsp;&amp;nbsp; &amp;nbsp;{
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;for(int i = t ; i &amp;gt; 0 ; 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;if((k-i) &amp;gt;=0 )
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;recursive(i,(k-i),t);
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}
&amp;nbsp;&amp;nbsp; &amp;nbsp;}
}
&lt;/pre&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題解小弟的解法大致上用樹的觀念&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;例如: &amp;nbsp; &amp;nbsp;t=3 &amp;nbsp; &amp;nbsp;k=-3&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;k&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; / &amp;nbsp; &amp;nbsp; | &amp;nbsp; &amp;nbsp; \&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; 1 &amp;nbsp; &amp;nbsp; 2 &amp;nbsp; &amp;nbsp; 3&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;/ &amp;nbsp;\ &amp;nbsp; &amp;nbsp;/&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;1 &amp;nbsp; 2 1&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;/&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;1&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2609182927746186917'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2609182927746186917'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/d810.html' title='高中 d810: 大朋友下樓梯'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-7209065308779233219</id><published>2010-12-12T00:09:00.004+08:00</published><updated>2011-01-09T21:20:51.836+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><category scheme="http://www.blogger.com/atom/ns#" term="心得感想"/><title type='text'>3 idiots</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&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/AVvXsEgQvZna9zz-g_EssaV6G3-PB0nbdIrEpAyObMw7R2ztnA0T5VIsw4KY-FIjWgJy58JlviqTcNho6VUp-DH6lvKwce0NVrYLurGP-1F_H7ohF_fx5GfZeZ2ZtEZAYI3K4lOnimUguV2eCWBx/s1600/bbs.cnscg.com%2540%25E4%25B8%2589%25E5%2582%25BB%25E5%25A4%25A7____.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgQvZna9zz-g_EssaV6G3-PB0nbdIrEpAyObMw7R2ztnA0T5VIsw4KY-FIjWgJy58JlviqTcNho6VUp-DH6lvKwce0NVrYLurGP-1F_H7ohF_fx5GfZeZ2ZtEZAYI3K4lOnimUguV2eCWBx/s1600/bbs.cnscg.com%2540%25E4%25B8%2589%25E5%2582%25BB%25E5%25A4%25A7____.jpg&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;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;片名：3 Idiots&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;譯名：三個傻瓜(三傻大鬧寶萊塢)&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;劇情簡介&lt;/span&gt;&lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia; font-size: 15px; line-height: 28px;&quot;&gt;：&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia; font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;此部電影以熱力歌舞和笑中帶淚的情節，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;呈現一齣思考教育本質、探討友誼真諦的喜劇史詩，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;因此，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;刷新印度最高票房紀錄。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;故事從印度一所理工名校展開，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;這裡許多學生，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;多是背負父母的壓力而入學就讀，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;法罕（馬德哈萬飾）、拉加（沙曼喬希飾）也不例外。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;然而，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;新生入宿這一天，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;一位富家子弟藍丘（阿米爾罕飾）的出現，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;卻改變了法罕和拉加的生命，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;這位活躍的小子不僅享受電機工程的樂趣，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;更大膽挑釁作風專制的學務主任。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;藍丘的特立獨行，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;不但啟發法罕及拉加這兩個好友，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;三人更起身反抗校內填鴨式的教育方針。&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;一段段勁爆瘋狂的冒險，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;也讓他們鬧出了不少笑料，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;藍丘更因緣巧合愛上了學務主任的女兒。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;然而，法罕與拉加仍扛著家庭加予的龐大壓力，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;眼看礙於現實，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;無法盡情追求夢想的兩人，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;又會遭逢什麼挑戰？&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;而藍丘，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;又為何會突然消失無蹤？&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;一場牽扯理想、愛情、身世的精采好戲，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;才正要展開…。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;本片改編自印度暢銷書《Five Point Someone》，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;男主角為當紅寶萊塢天王阿米爾罕，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;電影曾獲2010 印度奧斯卡最佳影片、最佳導演、最佳男配角獎。&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;場景則選在世界上海拔最高的公路之一的印度拉達克山區拍攝，&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;風景秀麗壯觀。&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-family: Georgia;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;font-size: 15px; line-height: 28px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;/div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Georgia; font-size: 15px; line-height: 28px;&quot;&gt;追求卓越，成功可能會隨之而來。&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/7209065308779233219'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/7209065308779233219'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/12/3-idiots.html' title='3 idiots'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEgQvZna9zz-g_EssaV6G3-PB0nbdIrEpAyObMw7R2ztnA0T5VIsw4KY-FIjWgJy58JlviqTcNho6VUp-DH6lvKwce0NVrYLurGP-1F_H7ohF_fx5GfZeZ2ZtEZAYI3K4lOnimUguV2eCWBx/s72-c/bbs.cnscg.com%2540%25E4%25B8%2589%25E5%2582%25BB%25E5%25A4%25A7____.jpg" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-3176595515066564613</id><published>2010-11-23T00:07:00.003+08:00</published><updated>2010-12-29T15:27:32.365+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>巨集與函數</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;巨集與函數的功能相同，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但在編譯時，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;編譯時會以巨集取代原來的敘述，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;而函數則是一個跳躍敘述；&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;在程式執行期間，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;由於巨集已經展開為它所代表的敘述，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;程式會一行一行執行下去，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;而碰到函數則是跳到函數定義的副程式去執行。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;所以，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;如果將子功能以巨集撰寫，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;執行速度較快，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但編譯後的程式碼較大；&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;函數寫法則執行速度較慢，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但是執行檔較小，&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;如何取捨完全看程式設計的目的與需求。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;巨集　(macro)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;優點：執行速度快，沒有堆疊的 push 和 pop 動作的需要，減少時間的耗損。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;缺點：巨集被呼叫多次以後，會耗損存放及使用大量的記憶體空間。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;函數　(call function/call subroutine)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;優點：即使函數被呼叫多次，在記憶體中仍只有一份實體，較節省記憶體空間。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;能節省存放及使用的記憶體空間。&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&amp;nbsp;&amp;nbsp;缺點：執行速度較慢，需花費時間在堆疊的　push 和 pop 動作上。&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://tw.myblog.yahoo.com/jw!IVek0_OCGh0D4Vskv8aDtA--/article?mid=46&quot;&gt;資料來源&lt;/a&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3176595515066564613'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3176595515066564613'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/11/blog-post_23.html' title='巨集與函數'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-4100425275059469985</id><published>2010-11-12T15:32:00.001+08:00</published><updated>2010-12-29T17:14:33.745+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="未分類"/><category scheme="http://www.blogger.com/atom/ns#" term="雜知識"/><title type='text'>員工遲到懶散會是好人才</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div&gt;&lt;br /&gt;
&lt;/div&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/AVvXsEj1mkseqK688aQHpWDZmggalLnALXtdc2vUn5tAZwSmhKHHyirO5gpjwYvG2dGnHsPw_r0SfQNz9kRih9mvd_K8NOfhCRrPpOGhEJuUYp4EypjkMwdki8kR83kO4vaE2b1o3g7brpH51uKi/s1600/47120_149501961739682_100000396386708_298093_8306332_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;clear: left; float: left; margin-bottom: 1em; margin-right: 1em;&quot;&gt;&lt;br /&gt;
&lt;/a&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1mkseqK688aQHpWDZmggalLnALXtdc2vUn5tAZwSmhKHHyirO5gpjwYvG2dGnHsPw_r0SfQNz9kRih9mvd_K8NOfhCRrPpOGhEJuUYp4EypjkMwdki8kR83kO4vaE2b1o3g7brpH51uKi/s1600/47120_149501961739682_100000396386708_298093_8306332_n.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;640&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj1mkseqK688aQHpWDZmggalLnALXtdc2vUn5tAZwSmhKHHyirO5gpjwYvG2dGnHsPw_r0SfQNz9kRih9mvd_K8NOfhCRrPpOGhEJuUYp4EypjkMwdki8kR83kO4vaE2b1o3g7brpH51uKi/s640/47120_149501961739682_100000396386708_298093_8306332_n.jpg&quot; width=&quot;248&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;小弟偶然看到這篇 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;雖然好像是很久的東西 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但看了之後還是有些感觸 ^_^&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;希望大家也可以有所體會&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/4100425275059469985'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/4100425275059469985'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/11/blog-post.html' title='員工遲到懶散會是好人才'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEj1mkseqK688aQHpWDZmggalLnALXtdc2vUn5tAZwSmhKHHyirO5gpjwYvG2dGnHsPw_r0SfQNz9kRih9mvd_K8NOfhCRrPpOGhEJuUYp4EypjkMwdki8kR83kO4vaE2b1o3g7brpH51uKi/s72-c/47120_149501961739682_100000396386708_298093_8306332_n.jpg" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-2580557198918124965</id><published>2010-11-12T12:46:00.007+08:00</published><updated>2011-01-10T10:56:43.136+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>C語言Qsort用法2</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;小弟上次Qsort講解的不好 ,(&lt;a href=&quot;http://rlong1106.blogspot.com/2010/10/cqsort.html#more&quot;&gt;上次的&lt;/a&gt;)&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;因此在這裡補上一彈 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;首先 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;先介紹C函式的網站 ,&lt;/span&gt;&lt;br /&gt;
&lt;a href=&quot;http://www.cplusplus.com/&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;http://www.cplusplus.com/&lt;/span&gt;&lt;/a&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;在那搜尋地方打上要的函式 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;將會有文字介紹 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;不過今天介紹結構排序 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;相信一用之後大家都懂了 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這部分是宣告的部分 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;struct In
    {
        double x , y ;
    } n[nodeAmount] ;
&lt;/pre&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這是將要自己提供的部分 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;int qsortXY(const void *a, const void *b) {
    struct In *intOne = (In*)a;
    struct In *intTwo = (In*)b;
    if ((intOne-&amp;gt;x) &amp;lt; (intTwo-&amp;gt;x))
        return -1;
    if ((intOne-&amp;gt;x) == (intTwo-&amp;gt;x)){
        if ((intOne-&amp;gt;y) &amp;lt; (intTwo-&amp;gt;y))
           return -1;
        if ((intOne-&amp;gt;y) == (intTwo-&amp;gt;y))
           return 0;
        return 1;
    }
    return 1;
}
&lt;/pre&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;在這裡講解一下qsort為何要自己寫一小段 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;qsort函式需收到一個值來做判別大小 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;以下是回傳值寫法 (qsort排序將由小至大),&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;a &amp;lt; b 時 return (負值) ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;a = b 時 return 0 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;a &amp;gt; b 時 return (正值) ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;若是想要排序由大至小 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;將上面的回傳值是正與負顛倒就沒問題 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;讓小弟上面回傳的程式碼是在一個平面上所用的 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;先排序x軸由小至大 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;若是x軸相等時 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;比較y軸 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;且一樣由小至大 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;今天提供了C函式查詢網站與qsort回傳值詳細介紹 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;相信大家對qsort又有更深一步的了解 ^_^&lt;/span&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2580557198918124965'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/2580557198918124965'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/11/cqsort2.html' title='C語言Qsort用法2'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-5330514832510307167</id><published>2010-10-24T22:04:00.005+08:00</published><updated>2010-12-29T15:27:32.367+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>C語言Qsort用法</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;今天要來介紹Qsort的用法 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;許多的問題都需要排序後才可解 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;然而排序也有分快與慢 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;公認排序時間平均最快的大概就是Qsort ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;因此我們今天的主角就是它了 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;再使用Qsort時必須include stdlib.h 檔 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;才能呼叫Qsort&amp;nbsp;,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;qsort的用法如下 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;qsort(陣列名稱,陣列長度,儲存大小,要自己寫的部分) ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這看起來有點難懂 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;換成程式寫法如下 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;array[arrayCount] ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;qsort(array,arrayCount,sizeof(array[0]),sortFunction)&amp;nbsp;,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這樣應該好懂許多 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;sortFunction這部分要自己寫 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;小弟也是直接拿別人的來使用 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;在這奉上程式碼&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;int sortFunction( const void *a, const void *b) {
&amp;nbsp;&amp;nbsp; &amp;nbsp;int intOne = *((int*)a);
&amp;nbsp;&amp;nbsp; &amp;nbsp;int intTwo = *((int*)b);
&amp;nbsp;&amp;nbsp; &amp;nbsp;if (intOne &amp;lt; intTwo)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;return -1;
&amp;nbsp;&amp;nbsp; &amp;nbsp;if (intOne == intTwo)
&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;return 0;
&amp;nbsp;&amp;nbsp; &amp;nbsp;return 1;
}
&lt;/pre&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5330514832510307167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/5330514832510307167'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/10/cqsort.html' title='C語言Qsort用法'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-3592581506207818273</id><published>2010-10-04T08:13:00.006+08:00</published><updated>2010-12-29T17:14:33.746+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="未分類"/><category scheme="http://www.blogger.com/atom/ns#" term="雜知識"/><title type='text'>四代 iPhone 規格比較</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;div&gt;&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: left;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi66wDA_hWDruOiqcnoVziVLDZyOQkumxgOXFDuz1mxRGZ0tM-N6dBcmsCwKiIIWdjpAbummomkTozaLVgYxwS19rcqMFYArVSUPoOp92YzEUqQlnb7A0v8bHu4nMTmUxOIUZE7BdPSL4Jf/s1600/img.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEi66wDA_hWDruOiqcnoVziVLDZyOQkumxgOXFDuz1mxRGZ0tM-N6dBcmsCwKiIIWdjpAbummomkTozaLVgYxwS19rcqMFYArVSUPoOp92YzEUqQlnb7A0v8bHu4nMTmUxOIUZE7BdPSL4Jf/s1600/img.jpg&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-family: Arial, Verdana, sans-serif; font-size: 15px; line-height: 10px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-family: Arial, Verdana, sans-serif; font-size: 15px; line-height: 10px;&quot;&gt;&lt;br /&gt;
&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;最近有種想買iphone的衝動阿~&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;就做了功課比較一下每一代的差異性&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;iphone 3GS 二手接近全新只要5千多&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;喔~不&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;結果是假的&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue; font-family: Arial, Verdana, sans-serif; font-size: medium;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;-webkit-border-horizontal-spacing: 10px; -webkit-border-vertical-spacing: 10px; font-size: 15px; line-height: 24px;&quot;&gt;害我心動了說...呵呵&lt;/span&gt;&lt;/span&gt;&lt;/div&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3592581506207818273'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3592581506207818273'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/10/iphone.html' title='四代 iPhone 規格比較'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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/AVvXsEi66wDA_hWDruOiqcnoVziVLDZyOQkumxgOXFDuz1mxRGZ0tM-N6dBcmsCwKiIIWdjpAbummomkTozaLVgYxwS19rcqMFYArVSUPoOp92YzEUqQlnb7A0v8bHu4nMTmUxOIUZE7BdPSL4Jf/s72-c/img.jpg" height="72" width="72"/></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-8022406573369257716</id><published>2010-10-03T21:43:00.008+08:00</published><updated>2010-12-29T15:27:32.368+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="C"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>char與ASCII</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;最近小弟被重修的同學問到了一個問題 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;疑?&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;這題似乎算重點之一 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;當下我就拾起手中的書看了一下 ,&lt;/span&gt;&lt;br /&gt;
&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;原來 ... 原來 ...&lt;/span&gt;&lt;br /&gt;
&lt;pre class=&quot;brush:html&quot;&gt;#include&amp;lt;stdio.h&amp;gt;
#include&amp;lt;stdlib.h&amp;gt;
int main() {
&amp;nbsp;&amp;nbsp; &amp;nbsp;char a = 367 ;
&amp;nbsp;&amp;nbsp; &amp;nbsp;printf(&quot;%c\n%d\n&quot;,a,a) ;
&amp;nbsp;&amp;nbsp; &amp;nbsp;system(&quot;pause&quot;);
}
&lt;/pre&gt;&lt;pre&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;
這執行結果會印出小&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;o&lt;/span&gt;與&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: red;&quot;&gt;111&lt;/span&gt; ,
&lt;div style=&quot;color: black; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; margin-top: 0px;&quot;&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;疑 ? &lt;/span&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;怎麼不是367 ?&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;原來直接宣告會是ASCII碼 ,&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;但ASCII碼表示又只有0~255(十進制) ,&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;因此367需要MOD 256變成了111 ,&lt;/span&gt;&lt;/div&gt;&lt;div&gt;&lt;span class=&quot;Apple-style-span&quot; style=&quot;color: blue;&quot;&gt;111的ASCII碼又是小o ,&lt;/span&gt;&lt;/div&gt;&lt;div&gt;又上了一課 ,&lt;/div&gt;&lt;div&gt;離偉大的程式設計師又邁向了一粒米的距離...&lt;/div&gt;&lt;/span&gt;
&lt;/pre&gt;</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/8022406573369257716'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/8022406573369257716'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/10/charascii.html' title='char與ASCII'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry><entry><id>tag:blogger.com,1999:blog-2891501055677273230.post-3558272863896321762</id><published>2010-09-09T23:23:00.008+08:00</published><updated>2010-12-29T15:24:54.029+08:00</updated><category scheme="http://www.blogger.com/atom/ns#" term="Android"/><category scheme="http://www.blogger.com/atom/ns#" term="學習"/><title type='text'>android 2.2 簡介</title><content type='html'>&lt;a name=&#39;more&#39;&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;a href=&quot;http://www.youtube.com/watch?v=yAZYSVr2Bhc&quot;&gt;http://www.youtube.com/watch?v=yAZYSVr2Bhc&lt;/a&gt;&lt;br /&gt;
這影片主要介紹Android2.2比先前版本突出的四大特性&lt;br /&gt;
1.Speed&lt;br /&gt;
2.APls and Services&lt;br /&gt;
3.Browser&lt;br /&gt;
4.Android Market&lt;br /&gt;
&lt;br /&gt;
還有這一部&lt;br /&gt;
&lt;a href=&quot;http://www.youtube.com/watch?v=pQb243niMlg&quot;&gt;http://www.youtube.com/watch?v=pQb243niMlg&lt;/a&gt;&lt;br /&gt;
介紹如何將PC上Google瀏覽器看到的網頁傳到手機上&lt;br /&gt;
也可以傳一段電話到手機上撥打&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
要完成 chrome to phone 有幾個要求(就是&lt;a href=&quot;http://www.youtube.com/watch?v=pQb243niMlg&quot;&gt;http://www.youtube.com/watch?v=pQb243niMlg&lt;/a&gt;)&lt;br /&gt;
1.android開發環境(小弟是用eclipse)&lt;br /&gt;
2.PC&lt;br /&gt;
3.gmail帳號&lt;br /&gt;
&lt;br /&gt;
首先我們先看PC端&lt;br /&gt;
1.先安裝chrome(google瀏覽器)&lt;br /&gt;
2.註冊帳號 &lt;a href=&quot;http://code.google.com/intl/zh-TW/android/c2dm/index.html&quot;&gt;http://code.google.com/intl/zh-TW/android/c2dm/index.html&lt;/a&gt;&lt;br /&gt;
3.chrome擴充工具&lt;br /&gt;
開啟瀏覽器 &amp;gt; 工具 &amp;gt; 擴充功能 &amp;gt; 找到能搜尋的地方打上chrome to phone&amp;nbsp;&amp;gt;&lt;br /&gt;
尋找Google Chrome to Phone Extension下載&lt;br /&gt;
&lt;br /&gt;
過來再看虛擬手機端&lt;br /&gt;
1.使用eclipse開啟 , 切記要用google APls 2.2 開啟&lt;br /&gt;
2.安裝Cloud to Device Messaging範例到手機上&lt;br /&gt;
3.在手機端登入gmail帳號&lt;br /&gt;
到設定的地方(Settings) &amp;gt; accounts &amp;amp; sync &amp;gt; add&amp;nbsp;account &amp;gt; 登入google帳號&lt;br /&gt;
4.手機端開啟&amp;nbsp;chrome to phone 並且一直下一步(第一個不用選)&lt;br /&gt;
&lt;br /&gt;
這樣就大功告成了 ,&lt;br /&gt;
就可以完成酷炫的&amp;nbsp;hrome to phone</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3558272863896321762'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/2891501055677273230/posts/default/3558272863896321762'/><link rel='alternate' type='text/html' href='http://rlong1106.blogspot.com/2010/09/android-22.html' title='android 2.2 簡介'/><author><name>JHANG RUEI-LONG</name><uri>http://www.blogger.com/profile/00622692729760582466</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></entry></feed>