<?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>GTTools.com &#187; C#</title>
	<atom:link href="http://gttools.com/tag/c/feed/" rel="self" type="application/rss+xml" />
	<link>http://gttools.com</link>
	<description></description>
	<lastBuildDate>Wed, 02 Mar 2011 16:52:20 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>How to iterate a C# dictionary</title>
		<link>http://gttools.com/2009/01/how-to-iterate-a-dicitonary/</link>
		<comments>http://gttools.com/2009/01/how-to-iterate-a-dicitonary/#comments</comments>
		<pubDate>Mon, 05 Jan 2009 23:07:23 +0000</pubDate>
		<dc:creator>GAT</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[collections]]></category>
		<category><![CDATA[howto]]></category>

		<guid isPermaLink="false">http://gttools.com/?p=65</guid>
		<description><![CDATA[The following snippet shows an easy way to iterate a C# dictionary: Dictionary&#60;int, string&#62; dictionary = new Dictionary&#60;int, string&#62;(); dictionary.Add(1, &#34;Cat&#34;); dictionary.Add(2, &#34;Dog&#34;); dictionary.Add(3, &#34;Horse&#34;); foreach (var item in dictionary) { // do stuff with item Console.WriteLine(string.Format(&#34;{0} - {1}&#34;, item.Key, &#8230; <a href="http://gttools.com/2009/01/how-to-iterate-a-dicitonary/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>The following snippet shows an easy way to iterate a C# dictionary:</p>
<pre class="brush: c#; ">

            Dictionary&lt;int, string&gt; dictionary = new Dictionary&lt;int, string&gt;();

            dictionary.Add(1, &quot;Cat&quot;);
            dictionary.Add(2, &quot;Dog&quot;);
            dictionary.Add(3, &quot;Horse&quot;);

            foreach (var item in dictionary)
            {
                // do stuff with item
                Console.WriteLine(string.Format(&quot;{0} - {1}&quot;, item.Key, item.Value));
            }

            // Result:
            // 1 - Cat
            // 2 - Dog
            // 3 - Horse
</pre>
]]></content:encoded>
			<wfw:commentRss>http://gttools.com/2009/01/how-to-iterate-a-dicitonary/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

