<?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>epicblog</title>
	<atom:link href="http://www.rickwargo.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.rickwargo.com</link>
	<description>Acquiring information, one day at a time.</description>
	<lastBuildDate>Wed, 03 Mar 2010 13:27:52 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0-alpha</generator>
		<item>
		<title>Recipe for Today&#8217;s Salad</title>
		<link>http://www.rickwargo.com/2010/03/02/recipe-for-todays-salad/</link>
		<comments>http://www.rickwargo.com/2010/03/02/recipe-for-todays-salad/#comments</comments>
		<pubDate>Tue, 02 Mar 2010 23:50:48 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[Recipe]]></category>
		<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=210</guid>
		<description><![CDATA[I just enjoyed a delicious salad made with the following ingredients (quantities are approximate):

1/2 large head chopped romaine
2 carrots, diced
1 stalk celery, diced
1 large red bell pepper, diced
1/3 small can sliced beets, diced
several artichoke hearts, diced
5 hearts of palm, diced
1/2 oz sunflower seeds
1 large plum tomato, diced
1 avocado, diced, large chunks
1 smallish sweet onion, diced
Walden [...]]]></description>
			<content:encoded><![CDATA[<p>I just enjoyed a delicious salad made with the following ingredients (quantities are approximate):</p>
<ul>
<li>1/2 large head chopped romaine</li>
<li>2 carrots, diced</li>
<li>1 stalk celery, diced</li>
<li>1 large red bell pepper, diced</li>
<li>1/3 small can sliced beets, diced</li>
<li>several artichoke hearts, diced</li>
<li>5 hearts of palm, diced</li>
<li>1/2 oz sunflower seeds</li>
<li>1 large plum tomato, diced</li>
<li>1 avocado, diced, large chunks</li>
<li>1 smallish sweet onion, diced</li>
<li><a href="http://www.amazon.com/exec/obidos/ASIN/B000U90MNG/epicblog-20">Walden Farms Honey Dijon Dressing</a> (Sugar Free, Calorie Free, Fat Free, Carb Free, Gluten Free) to taste</li>
<li>pepper to taste</li>
</ul>
<p>I used the <a href="http://www.amazon.com/exec/obidos/ASIN/B000F9JP3O/epicblog-20">Progressive International Fruit and Vegetable Chopper</a> to diced the veggies and it works beautifully. With all the different colors, the salad has a beautiful presentation and a taste to match.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2010/03/02/recipe-for-todays-salad/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Executing mailq as the nagios user on Fedora 12</title>
		<link>http://www.rickwargo.com/2010/01/13/executing-mailq-as-the-nagios-user-on-fedora-12/</link>
		<comments>http://www.rickwargo.com/2010/01/13/executing-mailq-as-the-nagios-user-on-fedora-12/#comments</comments>
		<pubDate>Wed, 13 Jan 2010 16:45:53 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=193</guid>
		<description><![CDATA[I added a new check command to nagios to check the sendmail mail queue but received an error while executing within nagios:
/usr/bin/mailq = can not chdir(/var/spool/mqueue/): Permission denied
Program mode requires special privileges, e.g., root or TrustedUser.
 CRITICAL: Error code 78 returned from /usr/bin/mailq

This is because the nagios process (which runs as the nagios user) does [...]]]></description>
			<content:encoded><![CDATA[<p>I added a new check command to nagios to check the sendmail mail queue but received an error while executing within nagios:</p>
<blockquote><p>/usr/bin/mailq = can not chdir(/var/spool/mqueue/): Permission denied<br />
Program mode requires special privileges, e.g., root or TrustedUser.<br />
 CRITICAL: Error code 78 returned from /usr/bin/mailq
</p></blockquote>
<p>This is because the nagios process (which runs as the nagios user) does not have the permissions to look at the spool directory for mail (/var/spool/mqueue) &#8211; the permissions on that directory are 700 and owned by root.</p>
<p>The fix is to permit nagios to execute this command as root and also to run the /usr/bin/mailq program with sudo in the check_mailq perl script.</p>
<p><strong>Step 1: Modify check_mailq</strong><br />
Edit the check_mailq file, after making a backup of the file. Search for the place where the mailq is opened for reading from the pipe and add /usr/bin/sudo prior to the command. The resulting line looks like the following (note: this is does using sendmail as the MTA):</p>
<p><code>if (! open (MAILQ, &quot;&lt;em&gt;&lt;strong&gt;/usr/bin/sudo &lt;/strong&gt;&lt;/em&gt;$utils::PATH_TO_MAILQ | &quot; ) ) {</code></p>
<p><strong>Step 2: Modify sudoers</strong><br />
Edit the sudoers file to give nagios permission to execute /usr/bin/mailq as root without requiring a password. I accomplished this by adding the following line to the end of the file:</p>
<p><pre><code>nagios&nbsp;&nbsp;ALL= (root)&nbsp;&nbsp;&nbsp;&nbsp; NOPASSWD: /usr/bin/mailq
</code></pre></p>
<p>Test prior to reloading nagios by executing the check_mailq command as nagios:</p>
<p><code>su nagios -c &quot;./check_mailq -w 5 -c 10&quot;</code></p>
<p>If you see an error message about a tty, like:</p>
<blockquote><p>sudo: sorry, you must have a tty to run sudo
</p></blockquote>
<p>or in nagios:</p>
<blockquote><p>CRITICAL: Error code 1 returned from /usr/bin/mailq
</p></blockquote>
<p>you will need to either comment out the line about requiring the tty (Defaults requiretty), or add a new line not requiring the tty for nagios:</p>
<p><pre><code>Defaults:nagios&nbsp;&nbsp;!requiretty
</code></pre></p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2010/01/13/executing-mailq-as-the-nagios-user-on-fedora-12/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Snow Leopard OS X DNS Issues</title>
		<link>http://www.rickwargo.com/2010/01/06/snow-leopard-os-x-dns-issues/</link>
		<comments>http://www.rickwargo.com/2010/01/06/snow-leopard-os-x-dns-issues/#comments</comments>
		<pubDate>Wed, 06 Jan 2010 16:33:13 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=179</guid>
		<description><![CDATA[Ever since upgrading to Snow Leopard, my MacBook Pro often was unable to see the local network hosts. It turns out the mDNSResponder, now responsible for DNS caching, is rotating the order of the DNS Servers. Since I have my own DNS server that is the authority for my network, this should always be the [...]]]></description>
			<content:encoded><![CDATA[<p>Ever since upgrading to Snow Leopard, my MacBook Pro often was unable to see the local network hosts. It turns out the mDNSResponder, now responsible for DNS caching, is rotating the order of the DNS Servers. Since I have my own DNS server that is the authority for my network, this should always be the first one checked. As it is also a home network, it made sense to have a backup DNS server pushed out via DHCP. However, it turns out that having the backup DNS server (my favorite: <a href="http://www.opendns.com/">OpenDNS</a>) in case the local one fails, actually causes the problem on the Snow Leopard machines.</p>
<p>I found a great amount of information regarding this at the <a href="http://discussions.apple.com/message.jspa?messageID=10851391">Apple Support Discussions</a> list. If this issue plagues you, many of the messages in this thread are a worthwhile read.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2010/01/06/snow-leopard-os-x-dns-issues/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Nagios and checking samba disks &#8211; check_disk_smb</title>
		<link>http://www.rickwargo.com/2010/01/06/nagios-and-checking-samba-disks-check_disk_smb/</link>
		<comments>http://www.rickwargo.com/2010/01/06/nagios-and-checking-samba-disks-check_disk_smb/#comments</comments>
		<pubDate>Wed, 06 Jan 2010 15:31:16 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>
		<category><![CDATA[nagios]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=175</guid>
		<description><![CDATA[The following is useful when the linux machine is not correctly joined to a domain:
I have noticed a number of PROBLEM alerts from my Nagios 3.2.0 implementation on Fedora 12 when checking the available disk space on a WinXP share such as:

Result from smbclient not suitable
No Answer from Client

This used to work before upgrading both [...]]]></description>
			<content:encoded><![CDATA[<p>The following is useful when the linux machine is not correctly joined to a domain:</p>
<p>I have noticed a number of PROBLEM alerts from my Nagios 3.2.0 implementation on Fedora 12 when checking the available disk space on a WinXP share such as:</p>
<ul>
<li>Result from smbclient not suitable</li>
<li>No Answer from Client</li>
</ul>
<p>This used to work before upgrading both my Nagios and Fedora implementations. </p>
<p>To get this working once again, I&#8217;ve had to do two things &#8211; allow Nagios to login and specify the domain name as part of the user name on the check_disk_smb command.</p>
<p>To permit login to nagios, edit the passwd file with sudo vipw and change the shell to /bin/sh for nagios (should have been /sbin/nologin).</p>
<p>Next, in the private configuration file for Nagios, change the USER variable to be DOMAIN\\\\User; note the four backslashes are necessary. If that USER variable is being used elsewhere where the the new value would alter the results from other Nagios checks, add a new USER variable and update the configuration files accordingly.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2010/01/06/nagios-and-checking-samba-disks-check_disk_smb/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing ZoneMinder 1.24.1 on Ubuntu 9.10</title>
		<link>http://www.rickwargo.com/2009/12/28/installing-zoneminder-1-24-1-on-ubuntu-9-10/</link>
		<comments>http://www.rickwargo.com/2009/12/28/installing-zoneminder-1-24-1-on-ubuntu-9-10/#comments</comments>
		<pubDate>Mon, 28 Dec 2009 17:37:03 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=171</guid>
		<description><![CDATA[Using a freshly installed version of Ubuntu 9.10, I was unable to successfully install zoneminder using the apt-get install zoneminder command. Instead I was getting messages such as:

Unknown database &#039;zm&#039; at /usr/share/perl5/ZoneMinder/Config.pm

To resolve I did the following (although I am not certain all the following steps were necessary):

Purged apache2, mysql-client, mysql-server, mysql-core, and zoneminder. I [...]]]></description>
			<content:encoded><![CDATA[<p>Using a freshly installed version of Ubuntu 9.10, I was unable to successfully install zoneminder using the apt-get install zoneminder command. Instead I was getting messages such as:<br />
<pre><code>
Unknown database &#039;zm&#039; at /usr/share/perl5/ZoneMinder/Config.pm
</code></pre><br />
To resolve I did the following (although I am not certain all the following steps were necessary):</p>
<ol>
<li>Purged apache2, mysql-client, mysql-server, mysql-core, and zoneminder. I did this using the Synaptic package manager but it just as easily be done using apt-get purge</li>
<li>I executed <code>sudo apt-get --purge autoremove</code> to clean all the additional packages</li>
<li>I installed libdirac0c2a and libdirac-dev</li>
<li>I installed mysql using <code>sudo apt-get install mysql-client mysql-server</code></li>
<li>I installed apache using <code>sudo apt-get install apache2</code></li>
<li>I removed the startup warning <em>apache2: Could not reliably determine the server&#8217;s fully qualified domain name, using 127.0.1.1 for ServerName</em> by adding ServerName <host> to the apache2.conf file in /etc/apache2.</li>
<li>Executed <code>sudo apt-get install apache2-mpm-prefork</code> to ensure it successfully restarted apache</li>
<li>Installed nullmailer using <code>sudo apt-get install nullmailer</code> and went through the configuration, setting my smarthost appropriately</li>
<li>Installed the additional dependencies for zoneminder to ensure they all were successful using <code>sudo apt-get install ...</code></li>
<li>Finally, I installed zoneminder successfully using <code>sudo apt-get install zoneminder</code>
</ol>
<p>I believe the tricks were to install the nullmailer separately and also purge the existing apache, mysql, and zoneminder installations prior to the install.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2009/12/28/installing-zoneminder-1-24-1-on-ubuntu-9-10/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exchange 2010 and 530 5.7.1 Client was not authenticated error</title>
		<link>http://www.rickwargo.com/2009/12/22/exchange-2010-and-530-5-7-1-client-was-not-authenticated-error/</link>
		<comments>http://www.rickwargo.com/2009/12/22/exchange-2010-and-530-5-7-1-client-was-not-authenticated-error/#comments</comments>
		<pubDate>Tue, 22 Dec 2009 15:58:35 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=165</guid>
		<description><![CDATA[My Exchange server is behind a Linux firewall with sendmail fronting the email handling. I started seeing messages in the maillog on the Linux machine like:
dsn=4.0.0, stat=Deferred: Connection reset by &#60;em&#62;mailserver&#60;/em&#62;.
Following that were even odder messages from SpamAssassin:
&#60;em&#62;mailhost&#60;/em&#62; mimedefang-multiplexor[1614]: Slave 0 stderr: dns: sendto() failed: Connection refused at /usr/lib/perl5/vendor_perl/5.10.0/Mail/SpamAssassin/DnsResolver.pm line 411.
&#60;em&#62;mailhost&#60;/em&#62; mimedefang-multiplexor[1614]: Slave 0 stderr: [...]]]></description>
			<content:encoded><![CDATA[<p>My Exchange server is behind a Linux firewall with sendmail fronting the email handling. I started seeing messages in the maillog on the Linux machine like:<br />
<code>dsn=4.0.0, stat=Deferred: Connection reset by &lt;em&gt;mailserver&lt;/em&gt;.</code></p>
<p>Following that were even odder messages from SpamAssassin:<br />
<pre><code>&lt;em&gt;mailhost&lt;/em&gt; mimedefang-multiplexor[1614]: Slave 0 stderr: dns: sendto() failed: Connection refused at /usr/lib/perl5/vendor_perl/5.10.0/Mail/SpamAssassin/DnsResolver.pm line 411.
&lt;em&gt;mailhost&lt;/em&gt; mimedefang-multiplexor[1614]: Slave 0 stderr: Use of uninitialized value in string ne at /usr/lib/perl5/vendor_perl/5.10.0/Mail/SpamAssassin/AsyncLoop.pm line 174.
&lt;em&gt;mailhost&lt;/em&gt; mimedefang-multiplexor[1614]: Slave 0 stderr: plugin: eval failed: oops, no key at /usr/lib/perl5/vendor_perl/5.10.0/Mail/SpamAssassin/AsyncLoop.pm line 174.</code></pre></p>
<p>This was all due to the added security of the Exchange Server installation (I believe it is also true for 2007). It is set up for authenticated connections and to disallow anonymous connections. </p>
<p>To resolve, I added a new Receive Connector in the Exchange Management Console for my sendmail front end machine under Hub Transport in the Server Configuration. I set this up to only receive mail from the IP Address for my sendmail machine and checked the <strong>Anonymous users</strong> permission group. Adding this new Receive Connector allowed email to be received from my sendmail machine once again.</p>
<p>In simpler terms:</p>
<ol>
<li>Open Exchange Management Console</li>
<li>Click on <em>Hub Transport</em> under <em>Server Configuration</em></li>
<li>Click on the corresponding hub in the top section</li>
<li>Right-click on the bottom section and add New Receive Connector</li>
<li>Using Custom as the intended use:</li>
<ol>
<li>Listen on Port 25</li>
<li>Enter the desired FQDN</li>
<li>Edit the IP Range to match the address of the sendmail machine</li>
<li>Create the New Reveice Connector</li>
</ol>
<li>After the Receive Connector is created, right-click on it and select <em>Properties</em></li>
<li>On the Permission Groups Properties tab, select <em>Anonymous users</em> and press OK</li>
</ol>
<p>A working system!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2009/12/22/exchange-2010-and-530-5-7-1-client-was-not-authenticated-error/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows Server 2008 R2 stuck during boot at Applying computer settings&#8230;</title>
		<link>http://www.rickwargo.com/2009/12/11/windows-server-2008-r2-stuck-during-boot-at-applying-computer-settings/</link>
		<comments>http://www.rickwargo.com/2009/12/11/windows-server-2008-r2-stuck-during-boot-at-applying-computer-settings/#comments</comments>
		<pubDate>Fri, 11 Dec 2009 15:46:43 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=156</guid>
		<description><![CDATA[Rebooted the server last night and the screen would not get past Applying computer settings&#8230; There seemed to be very light disk activity. I discovered that if I rebooted in Safe Mode with Networking and re-enabled the IPv6 on my Local Area Connection, the system would boot normally. I had turned it off earlier but [...]]]></description>
			<content:encoded><![CDATA[<p>Rebooted the server last night and the screen would not get past Applying computer settings&#8230; There seemed to be very light disk activity. I discovered that if I rebooted in Safe Mode with Networking and re-enabled the IPv6 on my Local Area Connection, the system would boot normally. I had turned it off earlier but had not rebooted since that change.</p>
<p><strong>Steps:</strong></p>
<ol>
<li>Right click on my network connection in the system tray and select Open Network and Sharing Center</li>
<li>Display the Local Area Connection Status</li>
<li>Click Properties and make sure Internet Protocol Version 6 (TCP/IPv6) is checked</li>
<li>Quit everything and reboot</li>
</ol>
<p>The only other potential factor was the server was behind a NAT; it could communicate with the local network but could not reach the outside world due to a misconfiguration in the firewall.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2009/12/11/windows-server-2008-r2-stuck-during-boot-at-applying-computer-settings/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problem upgrading my WinXP image to Parallels 4 (+ solution!)</title>
		<link>http://www.rickwargo.com/2009/03/15/problem-upgrading-my-winxp-image-to-parallels-4-solution/</link>
		<comments>http://www.rickwargo.com/2009/03/15/problem-upgrading-my-winxp-image-to-parallels-4-solution/#comments</comments>
		<pubDate>Sun, 15 Mar 2009 16:04:20 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[WILT]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=154</guid>
		<description><![CDATA[I&#8217;ve been struggling trying to upgrade my WinXP image after installing Parallels for on my MacBookPro. Every time I go to install Parallel tools, it just hangs after a while. Problem is that Windows thinks the underlying hardware has changed significantly so it is asking to re-activate the software.
At first, I didn&#8217;t have mouse access [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been struggling trying to upgrade my WinXP image after installing Parallels for on my MacBookPro. Every time I go to install Parallel tools, it just hangs after a while. Problem is that Windows thinks the underlying hardware has changed significantly so it is asking to re-activate the software.</p>
<p>At first, I didn&#8217;t have mouse access so I tried once again to install Parallel Tools; it hung again this time but after Force Quitting it, I had mouse and network access. Next I started the VM again and activated Windows. After that completed successfully, I was able to install Parallel Tools.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2009/03/15/problem-upgrading-my-winxp-image-to-parallels-4-solution/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Google Chrome</title>
		<link>http://www.rickwargo.com/2008/09/02/google-chrome/</link>
		<comments>http://www.rickwargo.com/2008/09/02/google-chrome/#comments</comments>
		<pubDate>Wed, 03 Sep 2008 00:12:49 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[Musings]]></category>
		<category><![CDATA[Google]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=148</guid>
		<description><![CDATA[Don&#8217;t most operating systems start with a command line? And what really is the Omnibox? I think it is the basis for the command line of the Internet.
]]></description>
			<content:encoded><![CDATA[<p>Don&#8217;t most operating systems start with a command line? And what <em>really</em> is the Omnibox? I think it is the basis for the command line of the Internet.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2008/09/02/google-chrome/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>What Technical Tests Do You Give Potential Hires?</title>
		<link>http://www.rickwargo.com/2008/05/02/what-technical-tests-do-you-give-potential-hires/</link>
		<comments>http://www.rickwargo.com/2008/05/02/what-technical-tests-do-you-give-potential-hires/#comments</comments>
		<pubDate>Fri, 02 May 2008 17:46:10 +0000</pubDate>
		<dc:creator>Rick Wargo</dc:creator>
				<category><![CDATA[Musings]]></category>

		<guid isPermaLink="false">http://www.rickwargo.com/?p=132</guid>
		<description><![CDATA[I&#8217;m amazed at how many candidates I&#8217;ve interviewed cannot provide an elegant solution to the following test:
Write a routine, in your favorite language or even a mock language, without using an intrinsic function to solve the problem for you, to reverse the contents of a string. The routine should take an input of a string [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m amazed at how many candidates I&#8217;ve interviewed cannot provide an elegant solution to the following test:</p>
<blockquote><p>Write a routine, in your favorite language or even a mock language, without using an intrinsic function to solve the problem for you, to reverse the contents of a string. The routine should take an input of a string and output a string. For example, if the input is &#8220;hello&#8221; the output should be &#8220;olleh&#8221;.</p></blockquote>
<p>I inform the candidate that it is a simple problem and invite them to talk through their logic as they write their solution on the whiteboard. I let them know it does not have to be syntactically correct; I am more interested in their approach. </p>
<p>It is enlightening, to say the least, to watch interviewees attack this problem. I&#8217;ve actually had so many people fail that I&#8217;ve been questioned if my &#8220;test&#8221; was too difficult. I understand there are abnormal pressures in play due to the setting but employees should ultimately perform decently under some pressure.</p>
<p>Silently I watch and listen to the candidate attempt to solve the problem. When the candidate is finished I usually ask, with good reason, are you certain this solution is correct? The response is often a &#8220;yes.&#8221; This usually gives us ample opportunity to talk about different strategies and try to understand why it was coded in a particular method.</p>
<p>I notice lots of issues that should not occur; for example, the candidate:</p>
<ul>
<li>does not understand the chosen language or it&#8217;s string libraries.</li>
<li>has issues with zero-based arrays depending on chosen language.</li>
<li>overly complicates the approach and never sits back to re-evaluate.</li>
<li>can not come up with a solution.</li>
<li>chooses a complicated approach involving math and gets the math wrong.</li>
<li>uses too many variables.</li>
<li>writes unnecessary code that essentially does nothing.</li>
<li>can not validate the output of the routine they wrote correctly.</li>
<li>writes more than ten lines of code to solve the problem.</li>
<li>does not know how to swap values in to variables properly.</li>
<li>&#8230; and many more.</li>
</ul>
<p>I&#8217;d appreciate others offering this simple test and sharing your results with me and everyone else. I&#8217;d also like to know your thoughts the validity of this test and how you would let the results affect your view of the candidate.</p>
<p>Before reading on to see my solution, try it for yourself. Let me know how you do.<br />
<span id="more-132"></span><br />
Here is my solution:<br />
<pre><code>static string reverse(string s)
{
&nbsp;&nbsp;&nbsp;&nbsp;string r = &quot;&quot;;

&nbsp;&nbsp;&nbsp;&nbsp;for (int i = s.Length - 1; i &gt;= 0; i--)
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;r += s[i];

&nbsp;&nbsp;&nbsp;&nbsp;return r;
}</code></pre></p>
<p>Can it be more simple? Let me know?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.rickwargo.com/2008/05/02/what-technical-tests-do-you-give-potential-hires/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
	</channel>
</rss>
