<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments for Geekality</title>
	<atom:link href="http://www.geekality.net/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.geekality.net</link>
	<description>With a hint of Social Ineptitude</description>
	<lastBuildDate>Fri, 09 Jul 2010 20:04:05 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>Comment on Project Euler: Problem 25 by Working with large numbers in C#: IntX &#171; Eventually Beta</title>
		<link>http://www.geekality.net/2009/11/06/project-euler-problem-25/#comment-647</link>
		<dc:creator>Working with large numbers in C#: IntX &#171; Eventually Beta</dc:creator>
		<pubDate>Fri, 09 Jul 2010 20:04:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=751#comment-647</guid>
		<description>[...] an example of how you can impliment IntX, again check out the homepage, or take a look at this blog which walks through one of the Project Euler problems using the IntX [...]</description>
		<content:encoded><![CDATA[<p>[...] an example of how you can impliment IntX, again check out the homepage, or take a look at this blog which walks through one of the Project Euler problems using the IntX [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on PHP: How to easily provide JSON and JSONP by Benjamin</title>
		<link>http://www.geekality.net/2010/06/27/php-how-to-easily-provide-json-and-jsonp/#comment-636</link>
		<dc:creator>Benjamin</dc:creator>
		<pubDate>Wed, 07 Jul 2010 10:52:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=1021#comment-636</guid>
		<description>Hi Torleif,

I have followed your instruction on jsonp. May firebug console still show the ajax request. May I know is there any more step which I have missed? I call url is as below:

http://test.com/gt_index.php?callback=jsonp1278499812769&amp;_=1278499813551

Thank you
Benjamin.</description>
		<content:encoded><![CDATA[<p>Hi Torleif,</p>
<p>I have followed your instruction on jsonp. May firebug console still show the ajax request. May I know is there any more step which I have missed? I call url is as below:</p>
<p><a href="http://test.com/gt_index.php?callback=jsonp1278499812769&amp;_=1278499813551" rel="nofollow">http://test.com/gt_index.php?callback=jsonp1278499812769&amp;_=1278499813551</a></p>
<p>Thank you<br />
Benjamin.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on PHP: How to easily provide JSON and JSONP by <img src='http://www.geekality.net/wp-content/plugins/rpx/images/openid.png'/> Torleif</title>
		<link>http://www.geekality.net/2010/06/27/php-how-to-easily-provide-json-and-jsonp/#comment-611</link>
		<dc:creator><img src='http://www.geekality.net/wp-content/plugins/rpx/images/openid.png'/> Torleif</dc:creator>
		<pubDate>Mon, 28 Jun 2010 08:37:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=1021#comment-611</guid>
		<description>Added charset to the content-type header, according to an answer to a question I posted about this on StackOverflow. &lt;a href=&quot;http://stackoverflow.com/questions/3128062/php-is-this-safe-for-providing-jsonp&quot; rel=&quot;nofollow&quot;&gt;PHP: Is this safe for providing JSONP?&lt;/a&gt;</description>
		<content:encoded><![CDATA[<p>Added charset to the content-type header, according to an answer to a question I posted about this on StackOverflow. <a href="http://stackoverflow.com/questions/3128062/php-is-this-safe-for-providing-jsonp" rel="nofollow">PHP: Is this safe for providing JSONP?</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Disappearing color labels in Mac OS X by Richard</title>
		<link>http://www.geekality.net/2010/03/19/disappearing-color-labels-in-mac-os-x/#comment-517</link>
		<dc:creator>Richard</dc:creator>
		<pubDate>Mon, 31 May 2010 23:50:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=937#comment-517</guid>
		<description>Your solution worked for me. Thanks!</description>
		<content:encoded><![CDATA[<p>Your solution worked for me. Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on The Sieve of Atkin in C# by Mark Lawrence</title>
		<link>http://www.geekality.net/2009/10/19/the-sieve-of-atkin-in-c/#comment-468</link>
		<dc:creator>Mark Lawrence</dc:creator>
		<pubDate>Sat, 22 May 2010 23:26:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=674#comment-468</guid>
		<description>Ok I don&#039;t know c# that well, but in your nested x/y for loops you compute both x * x and y * y three times, and 3 * x * x twice, could you compute these once only by using temporary variables?  The third computation of n is done, then you check that x &gt; y, why not perform this check first, then do the computation?</description>
		<content:encoded><![CDATA[<p>Ok I don&#8217;t know c# that well, but in your nested x/y for loops you compute both x * x and y * y three times, and 3 * x * x twice, could you compute these once only by using temporary variables?  The third computation of n is done, then you check that x &gt; y, why not perform this check first, then do the computation?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on When to check for null by <img src='http://www.geekality.net/wp-content/plugins/rpx/images/openid.png'/> Torleif</title>
		<link>http://www.geekality.net/2009/01/15/when-to-check-for-null/#comment-431</link>
		<dc:creator><img src='http://www.geekality.net/wp-content/plugins/rpx/images/openid.png'/> Torleif</dc:creator>
		<pubDate>Sat, 15 May 2010 11:14:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=48#comment-431</guid>
		<description>Seen it and tried to use it a bit. For example when I make things that returns iterators or arrays I try to always return empty ones instead of null. 

The colon-operator in Delphi Prism looks quite nice! In C# you have the ??-operator which is not as smooth, but still helps a bit with null checks. 

Instead of doing:

&lt;code lang=&quot;csharp&quot;&gt;var something = possibly_null != null ? possibly_null : alternative_if_null;&lt;/code&gt;

You can shorten it to:

&lt;code lang=&quot;csharp&quot;&gt;var something = possibly_null ?? alternative_if_null;&lt;/code&gt;

So if you had an object to represent a null or empty object you could do like this:

&lt;code lang=&quot;csharp&quot;&gt;var something = (some_container ?? Container.Empty).SomeProperty;&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>Seen it and tried to use it a bit. For example when I make things that returns iterators or arrays I try to always return empty ones instead of null. </p>
<p>The colon-operator in Delphi Prism looks quite nice! In C# you have the ??-operator which is not as smooth, but still helps a bit with null checks. </p>
<p>Instead of doing:</p>
<div class="codecolorer-container csharp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">var something <span style="color: #008000;">=</span> possibly_null <span style="color: #008000;">!=</span> <span style="color: #0600FF; font-weight: bold;">null</span> <span style="color: #008000;">?</span> possibly_null <span style="color: #008000;">:</span> alternative_if_null<span style="color: #008000;">;</span></div></div>
<p>You can shorten it to:</p>
<div class="codecolorer-container csharp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">var something <span style="color: #008000;">=</span> possibly_null <span style="color: #008000;">??</span> alternative_if_null<span style="color: #008000;">;</span></div></div>
<p>So if you had an object to represent a null or empty object you could do like this:</p>
<div class="codecolorer-container csharp default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="csharp codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">var something <span style="color: #008000;">=</span> <span style="color: #008000;">&#40;</span>some_container <span style="color: #008000;">??</span> Container<span style="color: #008000;">.</span><span style="color: #0000FF;">Empty</span><span style="color: #008000;">&#41;</span><span style="color: #008000;">.</span><span style="color: #0000FF;">SomeProperty</span><span style="color: #008000;">;</span></div></div>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Project Euler: Problem 1 by kjmRacing</title>
		<link>http://www.geekality.net/2009/09/15/project-euler-problem-1/#comment-399</link>
		<dc:creator>kjmRacing</dc:creator>
		<pubDate>Fri, 07 May 2010 05:33:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.geekality.net/?p=155#comment-399</guid>
		<description>the only proble is there should not be a semi colon in the Where

  var multiples = new long[] {3, 5};
  var answer =  Enumerable
    .Range(0, 1000)
    .Where(x =&gt; multiples.Any(y =&gt;&lt;strong&gt;;&lt;/strong&gt; x%y == 0))
    .Sum();</description>
		<content:encoded><![CDATA[<p>the only proble is there should not be a semi colon in the Where</p>
<p>  var multiples = new long[] {3, 5};<br />
  var answer =  Enumerable<br />
    .Range(0, 1000)<br />
    .Where(x =&gt; multiples.Any(y =&gt;<strong>;</strong> x%y == 0))<br />
    .Sum();</p>
]]></content:encoded>
	</item>
</channel>
</rss>
