<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Becoming a craftsman &#187; Uncategorized</title>
	<atom:link href="http://rock.hymasfamily.org/blog/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://rock.hymasfamily.org/blog</link>
	<description></description>
	<lastBuildDate>Sun, 18 Apr 2010 01:19:54 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Commitments</title>
		<link>http://rock.hymasfamily.org/blog/2010/03/08/commitments/</link>
		<comments>http://rock.hymasfamily.org/blog/2010/03/08/commitments/#comments</comments>
		<pubDate>Tue, 09 Mar 2010 01:12:30 +0000</pubDate>
		<dc:creator>Rock</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rock.hymasfamily.org/blog/?p=82</guid>
		<description><![CDATA[In my post on how to care, I committed to start blogging more regularly, rather than sporadically. I began last week by spending an hour on my commute each day doing writing and research for the post I published Saturday. On Sunday I took a break from the entire internet. I plan to continue with [...]]]></description>
			<content:encoded><![CDATA[<p style="margin: 0in; font-family: Calibri; font-size: 11.0pt;">In my post on how to care, I committed to start blogging more regularly, rather than sporadically. I began last week by spending an hour on my commute each day doing writing and research for the post I published Saturday. On Sunday I took a break from the entire internet. I plan to continue with that schedule. This coming week I&#8217;ll be eliminating some time-wasting websites from my life and replacing them with reviewing and acting on my next actions lists, including one for improving my blog. However, because I don&#8217;t want my blog to be primarily about blogging, or about my own personal growth, I&#8217;m not going to be publicly committing and reporting on my commitments here in the future. For those who care, they can see my current efforts on my public <a href="http://daytum.com/rockhymas">Daytum</a> page.</p>
]]></content:encoded>
			<wfw:commentRss>http://rock.hymasfamily.org/blog/2010/03/08/commitments/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Whimsical Walk</title>
		<link>http://rock.hymasfamily.org/blog/2009/05/01/whimsical-walk/</link>
		<comments>http://rock.hymasfamily.org/blog/2009/05/01/whimsical-walk/#comments</comments>
		<pubDate>Fri, 01 May 2009 22:40:39 +0000</pubDate>
		<dc:creator>Rock</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rock.hymasfamily.org/blog/2009/05/01/whimsical-walk/</guid>
		<description><![CDATA[In my last post I mentioned that I was doing some practice with the binary search algorithm. I wanted to approach it with a slightly different mindset and see what kind of an algorithm that led to. So I decided to think of it as a walk. I would go &#8220;visit&#8221; locations in the array [...]]]></description>
			<content:encoded><![CDATA[<p>In my last post I mentioned that I was doing some practice with the binary search algorithm. I wanted to approach it with a slightly different mindset and see what kind of an algorithm that led to. So I decided to think of it as a walk. I would go &#8220;visit&#8221; locations in the array and see if I should turn right or left at each one. Doing this in C meant that I could do some crazy stuff with arrays &#8211; nothing I would do in shipping code, but fun to play with nevertheless. Here is what I came up with:</p>
<pre style="background-color: white"><!--

Code highlighting produced by Actipro CodeHighlighter (freeware)

http://www.CodeHighlighter.com/

--><span style="color: #008080"> 1</span> <span style="color: #0000ff">char</span><span style="color: #000000"> ChopWalk(</span><span style="color: #0000ff">int</span><span style="color: #000000"> value, </span><span style="color: #0000ff">int</span><span style="color: #000000"> </span><span style="color: #000000">*</span><span style="color: #000000">array, </span><span style="color: #0000ff">int</span><span style="color: #000000"> size, </span><span style="color: #0000ff">int</span><span style="color: #000000"> </span><span style="color: #000000">*</span><span style="color: #000000">poffset)
</span><span style="color: #008080"> 2</span> <span style="color: #000000">{
</span><span style="color: #008080"> 3</span> <span style="color: #000000">    </span><span style="color: #0000ff">int</span><span style="color: #000000"> walkto </span><span style="color: #000000">=</span><span style="color: #000000"> size </span><span style="color: #000000">/</span><span style="color: #000000"> </span><span style="color: #800080">2</span><span style="color: #000000">;
</span><span style="color: #008080"> 4</span> <span style="color: #000000">    </span><span style="color: #0000ff">int</span><span style="color: #000000"> direction </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #800080">0</span><span style="color: #000000">;
</span><span style="color: #008080"> 5</span> <span style="color: #000000">    </span><span style="color: #0000ff">char</span><span style="color: #000000"> found </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #800080">0</span><span style="color: #000000">;
</span><span style="color: #008080"> 6</span> <span style="color: #000000">
</span><span style="color: #008080"> 7</span> <span style="color: #000000">    </span><span style="color: #0000ff">if</span><span style="color: #000000"> (walkto </span><span style="color: #000000">==</span><span style="color: #000000"> size)
</span><span style="color: #008080"> 8</span> <span style="color: #000000">        </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #800080">0</span><span style="color: #000000">;
</span><span style="color: #008080"> 9</span> <span style="color: #000000">
</span><span style="color: #008080">10</span> <span style="color: #000000">    </span><span style="color: #0000ff">if</span><span style="color: #000000"> (value </span><span style="color: #000000">==</span><span style="color: #000000"> array[walkto])
</span><span style="color: #008080">11</span> <span style="color: #000000">    {
</span><span style="color: #008080">12</span> <span style="color: #000000">        found </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #800080">1</span><span style="color: #000000">;
</span><span style="color: #008080">13</span> <span style="color: #000000">        direction </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #800080">0</span><span style="color: #000000">;
</span><span style="color: #008080">14</span> <span style="color: #000000">    }
</span><span style="color: #008080">15</span> <span style="color: #000000">    </span><span style="color: #0000ff">else</span><span style="color: #000000">
</span><span style="color: #008080">16</span> <span style="color: #000000">    {
</span><span style="color: #008080">17</span> <span style="color: #000000">        </span><span style="color: #0000ff">if</span><span style="color: #000000"> (value </span><span style="color: #000000">&gt;</span><span style="color: #000000"> array[walkto])
</span><span style="color: #008080">18</span> <span style="color: #000000">            direction </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #000000">+</span><span style="color: #800080">1</span><span style="color: #000000">;
</span><span style="color: #008080">19</span> <span style="color: #000000">        </span><span style="color: #0000ff">else</span><span style="color: #000000"> </span><span style="color: #0000ff">if</span><span style="color: #000000"> (value </span><span style="color: #000000">&lt;</span><span style="color: #000000"> array[walkto])
</span><span style="color: #008080">20</span> <span style="color: #000000">            direction </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #000000">-</span><span style="color: #800080">1</span><span style="color: #000000">;
</span><span style="color: #008080">21</span> <span style="color: #000000">        found </span><span style="color: #000000">=</span><span style="color: #000000"> ChopWalk(value, </span><span style="color: #000000">&amp;</span><span style="color: #000000">array[walkto </span><span style="color: #000000">+</span><span style="color: #000000"> direction], direction </span><span style="color: #000000">*</span><span style="color: #000000"> (size </span><span style="color: #000000">/</span><span style="color: #000000"> </span><span style="color: #800080">2</span><span style="color: #000000">), poffset);
</span><span style="color: #008080">22</span> <span style="color: #000000">    }
</span><span style="color: #008080">23</span> <span style="color: #000000">
</span><span style="color: #008080">24</span> <span style="color: #000000">    </span><span style="color: #000000">*</span><span style="color: #000000">poffset </span><span style="color: #000000">+=</span><span style="color: #000000"> walkto </span><span style="color: #000000">+</span><span style="color: #000000"> direction;
</span><span style="color: #008080">25</span> <span style="color: #000000">
</span><span style="color: #008080">26</span> <span style="color: #000000">    </span><span style="color: #0000ff">return</span><span style="color: #000000"> found;
</span><span style="color: #008080">27</span> <span style="color: #000000">}
</span><span style="color: #008080">28</span> <span style="color: #000000">
</span><span style="color: #008080">29</span> <span style="color: #000000"></span><span style="color: #0000ff">int</span><span style="color: #000000"> Chop(</span><span style="color: #0000ff">int</span><span style="color: #000000"> value, </span><span style="color: #0000ff">int</span><span style="color: #000000"> </span><span style="color: #000000">*</span><span style="color: #000000">array, </span><span style="color: #0000ff">int</span><span style="color: #000000"> size)
</span><span style="color: #008080">30</span> <span style="color: #000000">{
</span><span style="color: #008080">31</span> <span style="color: #000000">    </span><span style="color: #0000ff">int</span><span style="color: #000000"> result </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #800080">0</span><span style="color: #000000">;
</span><span style="color: #008080">32</span> <span style="color: #000000">    </span><span style="color: #0000ff">if</span><span style="color: #000000"> (ChopWalk(value, array, size, </span><span style="color: #000000">&amp;</span><span style="color: #000000">result))
</span><span style="color: #008080">33</span> <span style="color: #000000">        </span><span style="color: #0000ff">return</span><span style="color: #000000"> result;
</span><span style="color: #008080">34</span> <span style="color: #000000">    </span><span style="color: #0000ff">else</span><span style="color: #000000">
</span><span style="color: #008080">35</span> <span style="color: #000000">        </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #000000">-</span><span style="color: #800080">1</span><span style="color: #000000">;
</span><span style="color: #008080">36</span> <span style="color: #000000">}</span></pre>
]]></content:encoded>
			<wfw:commentRss>http://rock.hymasfamily.org/blog/2009/05/01/whimsical-walk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Practicing Binary Search</title>
		<link>http://rock.hymasfamily.org/blog/2009/04/24/practicing-binary-search/</link>
		<comments>http://rock.hymasfamily.org/blog/2009/04/24/practicing-binary-search/#comments</comments>
		<pubDate>Fri, 24 Apr 2009 16:52:59 +0000</pubDate>
		<dc:creator>Rock</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rock.hymasfamily.org/blog/2009/04/24/practicing-binary-search/</guid>
		<description><![CDATA[So for the last couple of weeks I&#8217;ve been practicing the binary search algorithm, as laid out by Dave Thomas here. I&#8217;ve done both iterative and recursive variations in C++ and then in C. I love the value of katas for learning new languages and features. I know both C++ and C, but doing this [...]]]></description>
			<content:encoded><![CDATA[<p>So for the last couple of weeks I&#8217;ve been practicing the binary search algorithm, as laid out by Dave Thomas <a href="http://codekata.pragprog.com/2007/01/kata_two_karate.html">here</a>. I&#8217;ve done both iterative and recursive variations in C++ and then in C. I love the value of katas for learning new languages and features. I know both C++ and C, but doing this simple problem in both programs allowed me to work on learning new areas in each. First, in C++ I took the time to use the standard template library (stl), because I&#8217;m not very familiar with it. I just used vectors in my tests, but it helped me to become familiar with the stl documentation and the concepts of iterators as used in the stl.</p>
<p>Next, I did the same variations in C. This was fun because C is so basic, and it&#8217;s been a long time since I coded in straight C. You don&#8217;t worry about concepts like objects or functional programming (though they may help you think about the problem). It gets you really close to the underlying physical model of computation. You&#8217;re forced to think more about how the memory is laid out, and how the algorithm takes advantage of that, whereas with C++ and the stl the whole problem and the solution are more abstract, just slightly more removed from hardware.</p>
<p>In addition to the languages themselves, it&#8217;s also a chance to practice my use of tools. I used the work to hone my skills in vim, to understand our build system at work more fully, and to consider testing frameworks.</p>
]]></content:encoded>
			<wfw:commentRss>http://rock.hymasfamily.org/blog/2009/04/24/practicing-binary-search/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Speed up Tasks on Your Windows Mobile Smartphone</title>
		<link>http://rock.hymasfamily.org/blog/2008/03/31/speed-up-tasks-on-your-windows-mobile-smartphone/</link>
		<comments>http://rock.hymasfamily.org/blog/2008/03/31/speed-up-tasks-on-your-windows-mobile-smartphone/#comments</comments>
		<pubDate>Mon, 31 Mar 2008 20:14:59 +0000</pubDate>
		<dc:creator>Rock</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://rock.hymasfamily.org/blog/2008/03/31/speed-up-tasks-on-your-windows-mobile-smartphone/</guid>
		<description><![CDATA[One of my biggest frustrations with the Windows Mobile task application is that it synchronizes your completed tasks. After a while, this greatly outnumbers your active tasks, making the task app really slow. So I periodically move my completed tasks to a separate task folder (I like to have them around for searching). Alternatively, you [...]]]></description>
			<content:encoded><![CDATA[<p>One of my biggest frustrations with the Windows Mobile task application is that it synchronizes your completed tasks. After a while, this greatly outnumbers your active tasks, making the task app really slow. So I periodically move my completed tasks to a separate task folder (I like to have them around for searching). Alternatively, you could just delete them once a week or so. The following Outlook macro code can be used to move all the completed tasks in your tasks folder to the first tasks subfolder.</p>
<p><!-- code formatted by http://manoli.net/csharpformat/ --></p>
<pre class="csharpcode">    <span class="kwrd">Dim</span> fld <span class="kwrd">As</span> Folder
    <span class="kwrd">Dim</span> fldComplete <span class="kwrd">As</span> Folder

    <span class="kwrd">Set</span> fld = Application.GetNamespace(<span class="str">"MAPI"</span>).GetDefaultFolder(olFolderTasks)
    <span class="kwrd">Set</span> fldComplete = fld.Folders.Item(1)
    <span class="kwrd">For</span> x = fld.Items.Count <span class="kwrd">To</span> 1 <span class="kwrd">Step</span> -1
        <span class="kwrd">Dim</span> objTask <span class="kwrd">As</span> TaskItem
        <span class="kwrd">Set</span> objTask = fld.Items(x)
        <span class="kwrd">If</span> (objTask.Complete) <span class="kwrd">Then</span>
            objTask.Move fldComplete
        <span class="kwrd">End</span> <span class="kwrd">If</span>
    <span class="kwrd">Next</span> x</pre>
]]></content:encoded>
			<wfw:commentRss>http://rock.hymasfamily.org/blog/2008/03/31/speed-up-tasks-on-your-windows-mobile-smartphone/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
