<?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>.NET Tips and Tricks &#187; Interview Questions</title>
	<atom:link href="http://kossovsky.net/index.php/category/interview-questions/feed/" rel="self" type="application/rss+xml" />
	<link>http://kossovsky.net</link>
	<description>C# Code Snippets, ASP.NET Code Samples, .NET Tips and Tricks</description>
	<lastBuildDate>Sat, 25 Dec 2010 08:32:05 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>Division by zero is simple, isn&#8217;t it ?</title>
		<link>http://kossovsky.net/index.php/2010/04/division-by-zero-is-simple-but-the-result-not/</link>
		<comments>http://kossovsky.net/index.php/2010/04/division-by-zero-is-simple-but-the-result-not/#comments</comments>
		<pubDate>Sun, 04 Apr 2010 19:17:00 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[according to the rules]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[divide]]></category>
		<category><![CDATA[elementary arithmetic]]></category>
		<category><![CDATA[few days]]></category>
		<category><![CDATA[floating point]]></category>
		<category><![CDATA[floating point numbers]]></category>
		<category><![CDATA[infinity]]></category>
		<category><![CDATA[large numbers]]></category>
		<category><![CDATA[microsoft]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[running]]></category>
		<category><![CDATA[ugly bug]]></category>
		<category><![CDATA[visual c#]]></category>
		<category><![CDATA[zero]]></category>
		<category><![CDATA[zero exception]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=834</guid>
		<description><![CDATA[I&#8217;m sure you all know that according to the rules of elementary arithmetic division by zero is not allowed*. Also, I&#8217;m pretty sure you are familiar with the &#8220;Attempted to divide by zero&#8221; exception and some of you even write a specific catch in try&#8230;catch blocks to catch the DivideByZeroException to be able to handle [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (4 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m sure you all know that according to the rules of elementary arithmetic division by zero is not allowed*. Also, I&#8217;m pretty sure you are familiar with the &#8220;Attempted to divide by zero&#8221; exception and some of you even write a specific catch in try&#8230;catch blocks to catch the DivideByZeroException to be able to handle it according to your application needs.</p>
<p><span id="more-834"></span><br />
A few days ago I had to solve some very ugly bug that was caused by exactly the same approach I mentioned.</p>
<p>The code contained some calculation with a very large numbers and some how the results weren&#8217;t close to what we expected.</p>
<p>Let&#8217;s see some code</p>
<pre class="c-sharp" name="code">
            // Example #2
            var firstValue = 3;
            var secondValue = 0;
            var result = firstValue / secondValue;
</pre>
<p> Simple, isn&#8217;t it. Running the above code will throw DivideByZeroException exception as we all expected.</p>
<p><br/><br />
Now look at the following code. Will it behave the same way ?</p>
<pre class="c-sharp" name="code">
            // Example #2
            var firstValue = 3.5;
            var secondValue = 0;
            var result = firstValue / secondValue;
</pre>
<p>As you probably suspected &#8211; it won&#8217;t. It will run and complete without throwing any exception at all.<br />
So, what happened here ? Are we talking about some serious bug Microsoft isn&#8217;t aware of ? </p>
<p>Well, first of all it is not a bug. The difference between the two examples is the type we are trying to divide by zero. In the first example firstValue is an Integer and in the second example is Double.</p>
<p>Does that mean we can divide floating point numbers by zero ? Yes we can.</p>
<p>Now you are probably wondering what will be the the value of result. Well, the answer is &#8211; Infinity. Yes, there is a value called Infinity and to be more specific, in our case the result is a Positive Infinity. The interesting part is because Infinity is a value you can make calculations with it and it won&#8217;t throw any exception. Let&#8217;s see some examples :</p>
<pre class="c-sharp" name="code">
            var i = 3.5 / 0;                // Infinity
            var t1 = i++;                   // Infinity
            var t2 =  i--;                  // Infinity
            var t3 = i/i;                   // NaN
            var t4 = i * i;                 // Infinity
            var t5 = i>0;                   // true
            var t6 = i > double.MaxValue;   // true
            var t7 = double.MaxValue - i;   // -Infinity [ Negative Infinity ]
            var t8 = i-i;                   // NaN
</pre>
<p>So, now we know that calculations using Infinity are possible but in most cases the result won&#8217;t be something you can use for further calculation. By the way, if you will try to insert Infinity into Microsoft SQL field (at least in 2005) it will throw an exception saying &#8220;The supplied value is not a valid instance of data type float&#8221;.</p>
<p>And now i would like to return to the bug i was talking about at the beginning of this post.<br />
What do you think will be the result of the following code.</p>
<pre class="c-sharp" name="code">
            var i = 3.5 / 0;
            var result = (long)i;
</pre>
<p>The result is very numeric, not NaN and not Infinite but -9223372036854775808.<br />
Now imagine situation when you must calculate some numbers that represent money, I mean loans, balance, etc. I&#8217;m sure you can easily understand how far can it go and which unpleasant result we can get.</p>
<p>C# provide us some usefull functions and constants we can and must use to avoid the above mistakes.</p>
<pre class="c-sharp" name="code">
            //  Returns a value indicating whether the specified number
            //  evaluates to negative or positive infinity
            double.IsInfinity(double d) 

            //  Returns a value indicating whether the specified number
            // evaluates to negative infinity.
            double.IsNegativeInfinity (double d)

            //  Returns a value indicating whether the specified number
            //  evaluates to positive infinity.
            double.IsPositiveInfinity (double d)

            //  Represents negative infinity. This field is constant.
            double.NegativeInfinity 

            //  Represents positive infinity. This field is constant.
            double.PositiveInfinity

            //  Represents a value that is not a number (NaN).
            //  This field is constant.
            double.NaN
</pre>
<p>Floating point is necessary in so many cases &#8211; use it wisely and carefully.</p>
<div>
<script type="text/javascript">
var dzone_url = 'http://kossovsky.net/index.php/2010/04/division-by-zero-is-simple-but-the-result-not/';
var dzone_style = '1';
</script><br />
<script language="javascript" src="http://widgets.dzone.com/links/widgets/zoneit.js"></script>
</div>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (4 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2010%2F04%2Fdivision-by-zero-is-simple-but-the-result-not%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2010/04/division-by-zero-is-simple-but-the-result-not/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Javascript boolean interpretation</title>
		<link>http://kossovsky.net/index.php/2009/07/javascript-boolean-interpretation/</link>
		<comments>http://kossovsky.net/index.php/2009/07/javascript-boolean-interpretation/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 08:16:27 +0000</pubDate>
		<dc:creator>Maxim</dc:creator>
				<category><![CDATA[Browser]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[about true]]></category>
		<category><![CDATA[alert message]]></category>
		<category><![CDATA[boolean interpretation]]></category>
		<category><![CDATA[boolean values]]></category>
		<category><![CDATA[document write]]></category>
		<category><![CDATA[eval]]></category>
		<category><![CDATA[javascript boolean]]></category>
		<category><![CDATA[javascript browser]]></category>
		<category><![CDATA[principle]]></category>
		<category><![CDATA[simple questions]]></category>
		<category><![CDATA[Tips and Tricks]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=613</guid>
		<description><![CDATA[How to deal with JavaScript boolean values, what will be evaluated as true and what as false !!!!.<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>I have two simple questions for you about boolean values in Javascript.<br />
When will  browser show alert message:</p>
<pre class="javascript" name="code">
        if (a-b) alert("it's true!");
</pre>
<p>And another one<br />
<span id="more-613"></span><br />
What will be printed as result of running this script:</p>
<pre class="javascript" name="code">
	for (var n=10; n; n-- )
	{
		document.write (n + ",");
	}
</pre>
<p>The answer for both questions relies on the same principle of what JavaScript engine will evaluate as true and what as false.</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F07%2Fjavascript-boolean-interpretation%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/07/javascript-boolean-interpretation/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>C# LINQ Teaser</title>
		<link>http://kossovsky.net/index.php/2009/07/csharp-linq-teaser/</link>
		<comments>http://kossovsky.net/index.php/2009/07/csharp-linq-teaser/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 09:31:00 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Teasers]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[delegate]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[interview question]]></category>
		<category><![CDATA[lambda]]></category>
		<category><![CDATA[linq]]></category>
		<category><![CDATA[lt]]></category>
		<category><![CDATA[main string]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[Puzzle]]></category>
		<category><![CDATA[puzzles]]></category>
		<category><![CDATA[string args]]></category>
		<category><![CDATA[tezer]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[toarray]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=517</guid>
		<description><![CDATA[Another great interview question. Will the following code compile and if yes what will be the result of it ? static void Main(string[] args) { int[] array = new[] {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}; Func&#60;int, int&#62; func = i =&#62; { Console.Write(array[i]); return i; }; var result = array.Where(e =&#62; [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.8" /></div><div>Rating: 4.8/<strong>5</strong> (9 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>Another great interview question.</p>
<p>Will the following code compile and if yes what will be the result of it ?<br />
<span id="more-517"></span></p>
<pre class="c#" name="code">static void Main(string[] args)
{
    int[] array = new[] {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};

    Func&lt;int, int&gt; func = i =&gt; {
                          Console.Write(array[i]);
                          return i;
                     };

    var result = array.Where(e =&gt; e &lt;= func(2)).ToArray ();
}</pre>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.8" /></div><div>Rating: 4.8/<strong>5</strong> (9 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F07%2Fcsharp-linq-teaser%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/07/csharp-linq-teaser/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>C# Byte Iteration Question</title>
		<link>http://kossovsky.net/index.php/2009/07/csharp-byte-iteration-question/</link>
		<comments>http://kossovsky.net/index.php/2009/07/csharp-byte-iteration-question/#comments</comments>
		<pubDate>Fri, 10 Jul 2009 08:27:34 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Teasers]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[byte]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[interview question]]></category>
		<category><![CDATA[iteration]]></category>
		<category><![CDATA[main string]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[string args]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=473</guid>
		<description><![CDATA[This one is a great c# interview question &#8211; short and simple, but tricky. static void Main(string[] args) { for (byte b = byte.MinValue; b<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.4" /></div><div>Rating: 4.4/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>This one is a great c# interview question &#8211; short and simple, but tricky.</p>
<p><span id="more-473"></span></p>
<pre class="c-sharp" name="code">
static void Main(string[] args)
{
    for (byte b = byte.MinValue; b <= byte.MaxValue; b++)
        Console.Write(b);
}

// A little tip
// byte.MinValue = 0
// byte.MaxValue = 255
</pre>
<p>How many times the above statement will be executed ?</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.4" /></div><div>Rating: 4.4/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F07%2Fcsharp-byte-iteration-question%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/07/csharp-byte-iteration-question/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>C# The &#8220;double&#8221; trouble</title>
		<link>http://kossovsky.net/index.php/2009/07/csharp-the-double-trouble/</link>
		<comments>http://kossovsky.net/index.php/2009/07/csharp-the-double-trouble/#comments</comments>
		<pubDate>Mon, 06 Jul 2009 21:37:16 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Optimization]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[QA]]></category>
		<category><![CDATA[Teasers]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[d1 d2]]></category>
		<category><![CDATA[digits]]></category>
		<category><![CDATA[double]]></category>
		<category><![CDATA[double trouble]]></category>
		<category><![CDATA[floating]]></category>
		<category><![CDATA[floating point]]></category>
		<category><![CDATA[guarantees]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[main string]]></category>
		<category><![CDATA[math]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[numeric value]]></category>
		<category><![CDATA[point]]></category>
		<category><![CDATA[precision]]></category>
		<category><![CDATA[Puzzle]]></category>
		<category><![CDATA[simple answer]]></category>
		<category><![CDATA[string args]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Tricks]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=360</guid>
		<description><![CDATA[This is a very simple question with a not so simple answer&#8230; Forget for a second about .NET. If someone asks you how much is 1.000025 &#8211; 0.000025 your answer will probably be &#8220;1&#8243; and correct. An easy question, right ? Now, let&#8217;s go back to .NET and check if our calculations are correct. static [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.3" /></div><div>Rating: 4.3/<strong>5</strong> (6 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>This is a very simple question with a not so simple answer&#8230;</p>
<p>Forget for a second about .NET.<br />
If someone asks you how much is 1.000025 &#8211; 0.000025 your answer will probably be &#8220;1&#8243; and correct. An easy question, right ?</p>
<p>Now, let&#8217;s go back to .NET and check if our calculations are correct.</p>
<p><span id="more-360"></span></p>
<pre class="c-sharp" name="code">        static void Main(string[] args)
        {
            double d1 = 1.000025;
            double d2 = 0.000025;
            Console.WriteLine((d1 - d2) == 1);
        }</pre>
<p>If you think the result will be &#8220;true&#8221;&#8230; well, it&#8217;s not.</p>
<p>Let&#8217;s see another example :</p>
<pre class="c-sharp" name="code">        static void Main(string[] args)
        {
            double d1 = 1.000025;
            double d2 = 0.000025;

            // Will result 1
            Console.WriteLine(d1 - d2);

            // Will result 0.99999999999999989
            Console.WriteLine((d1 - d2).ToString ("R"));
        }</pre>
<p>For those who might not know, the meaning of ToString(&#8220;R&#8221;) is <a title="MSDN - Standard Numeric Format Strings" href="http://msdn.microsoft.com/en-us/library/dwhawy9k.aspx" target="_blank">Round-trip</a>.</p>
<blockquote><p>This format is supported only for the Single and Double types. The round-trip specifier guarantees that a numeric value converted to a string will be parsed back into the same numeric value. When a numeric value is formatted using this specifier, it is first tested using the general format, with 15 spaces of precision for a Double and 7 spaces of precision for a Single. If the value is successfully parsed back to the same numeric value, it is formatted using the general format specifier. However, if the value is not successfully parsed back to the same numeric value, then the value is formatted using 17 digits of precision for a Double and 9 digits of precision for a Single.</p></blockquote>
<p>So, what happened here ? Is it a bug ?<br />
The answer is &#8211; NO, IT&#8217;S NOT A BUG ( and it&#8217;s not happening only on my computer ).</p>
<p>The thing is, that the above is about how .NET rounding a floating point number.<br />
I won&#8217;t explain here the math ( there is already a great <a title="What Every Computer Scientist Should Know About Floating-Point Arithmetic" href="http://docs.sun.com/source/806-3568/ncg_goldberg.html" target="_blank">article</a> explaining it ), and i won&#8217;t say don&#8217;t use floating point types.</p>
<p>You just need to know that when you are using it &#8211; be carefull, especialy in equations and formatting, otherwise your calculations will be wrong and your result not accurate.</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.3" /></div><div>Rating: 4.3/<strong>5</strong> (6 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F07%2Fcsharp-the-double-trouble%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/07/csharp-the-double-trouble/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>C# Increment operator (++) question</title>
		<link>http://kossovsky.net/index.php/2009/07/csharp-increment-operator-question/</link>
		<comments>http://kossovsky.net/index.php/2009/07/csharp-increment-operator-question/#comments</comments>
		<pubDate>Tue, 30 Jun 2009 22:30:32 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Teasers]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[dot net]]></category>
		<category><![CDATA[dotnet]]></category>
		<category><![CDATA[increment]]></category>
		<category><![CDATA[increment operator]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[main string]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[operators]]></category>
		<category><![CDATA[puzzles]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=293</guid>
		<description><![CDATA[Well, this is a nice one. We all familiar with incremental operators, but from what i saw yesterday&#8230; well, there is no need to give a developer some tricky assignment so he could find a way to make some bugs. 3bj4h786fc What will be the output of the next code ? static void Main(string[] args) [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (6 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>Well, this is a nice one. We all familiar with incremental operators, but from what i saw yesterday&#8230; well, there is no need to give a developer some tricky assignment so he could find a way to make some bugs.</p>
<div style="display:none">3bj4h786fc</div>
<p><span id="more-293"></span><br />
What will be the output of the next code ?</p>
<pre class="c-sharp" name="code">
static void Main(string[] args)
{
    int i = 100;
    for (int n = 0; n < 100; n++)
    {
         i = i++;
    }
    Console.WriteLine(i);
}
</pre>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=5.0" /></div><div>Rating: 5.0/<strong>5</strong> (6 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F07%2Fcsharp-increment-operator-question%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/07/csharp-increment-operator-question/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>SQL 2005 &#8211; Return query rows as one delimited column</title>
		<link>http://kossovsky.net/index.php/2009/06/sql-2005-return-rows-as-delimited-column/</link>
		<comments>http://kossovsky.net/index.php/2009/06/sql-2005-return-rows-as-delimited-column/#comments</comments>
		<pubDate>Tue, 30 Jun 2009 09:34:28 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL 2005]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[XML]]></category>
		<category><![CDATA[column]]></category>
		<category><![CDATA[concatenate]]></category>
		<category><![CDATA[concatenating]]></category>
		<category><![CDATA[customer id]]></category>
		<category><![CDATA[delimited]]></category>
		<category><![CDATA[for xml path]]></category>
		<category><![CDATA[lt]]></category>
		<category><![CDATA[microsoft sql]]></category>
		<category><![CDATA[query]]></category>
		<category><![CDATA[root root]]></category>
		<category><![CDATA[several ways]]></category>
		<category><![CDATA[sql query]]></category>
		<category><![CDATA[sql server]]></category>
		<category><![CDATA[sql server 2005]]></category>
		<category><![CDATA[t-sql]]></category>
		<category><![CDATA[table]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[xml path]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=272</guid>
		<description><![CDATA[Once in a while we need to return data from SQL as delimited string of values and not as rows. There are several ways to do that, but personally i like the next one. SELECT CustomerID AS 'data()' FROM Customer FOR XML PATH('') -- This will result one column with a value like this: 1 [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.6" /></div><div>Rating: 4.6/<strong>5</strong> (7 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>Once in a while we need to return data from SQL as delimited string of values and not as rows. There are several ways to do that, but personally i like the next one.</p>
<p><span id="more-272"></span></p>
<pre class="sql:nogutter" name="code">
SELECT CustomerID AS 'data()'
FROM Customer
FOR XML PATH('')
-- This will result one column with a value like this: 1 2 3 4 5 6 7 8

-- And to get the column as part of some other query:
SELECT CustomerID,
       (SELECT OrderID AS 'data()'
       FROM Order O WHERE O.CustomerID = C.Customer ID
       FOR XML PATH('')) AS OrderList
FROM Customer C

-- The result of the above query will be something like this :
-- CustomerID	| OrderList
-- --------------------------------
-- 1		    | 1 2 5 9 90 200
-- 2		    | 2 7 10 22
-- 3		    | 12 17 246
-- 4		    | 83 92 1002

-- And of course we could return it as XML
SELECT CustomerID AS '@id',
       (SELECT OrderID AS 'data()'
       FROM Order O WHERE O.CustomerID = C.Customer ID
       FOR XML PATH('')) AS '@ordelist'
FROM Customer C
FOR XML PATH('customer'), ROOT('root')

-- The result of the above query will be something like this :
&lt;root&gt;
  &lt;customer id="1" orderlist="1 2 5 9 90 200"/&gt;
  &lt;customer id="2" orderlist="2 7 10 22"/&gt;
  &lt;customer id="3" orderlist="12 17 246"/&gt;
  &lt;customer id="4" orderlist="83 92 1002"/&gt;
&lt;/root&gt;
</pre>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.6" /></div><div>Rating: 4.6/<strong>5</strong> (7 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F06%2Fsql-2005-return-rows-as-delimited-column%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/06/sql-2005-return-rows-as-delimited-column/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>C# string.Empty vs &#8220;&#8221;</title>
		<link>http://kossovsky.net/index.php/2009/06/string-empty-versus-empty-quotes/</link>
		<comments>http://kossovsky.net/index.php/2009/06/string-empty-versus-empty-quotes/#comments</comments>
		<pubDate>Sun, 28 Jun 2009 22:08:33 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Optimization]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[c# string]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[compilation error]]></category>
		<category><![CDATA[console switch]]></category>
		<category><![CDATA[empty]]></category>
		<category><![CDATA[empty quotes]]></category>
		<category><![CDATA[empty string]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[puzzles]]></category>
		<category><![CDATA[quotes]]></category>
		<category><![CDATA[string]]></category>
		<category><![CDATA[string value]]></category>
		<category><![CDATA[string.cs]]></category>
		<category><![CDATA[string.Empty]]></category>
		<category><![CDATA[test string]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[two ways]]></category>
		<category><![CDATA[variable value]]></category>
		<category><![CDATA[visual c#]]></category>
		<category><![CDATA[writeline]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=263</guid>
		<description><![CDATA[As we know we have two ways to set a variable value to an empty string. We can just set it to empty quotes &#8220;&#8221; or set it to string.Empty, but what is the difference and is there one at all ? If we will look at the .NET String.cs we will see the next [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.2" /></div><div>Rating: 4.2/<strong>5</strong> (9 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>As we know we have two ways to set a variable value to an empty string.<br />
We can just set it to empty quotes &#8220;&#8221; or set it to string.Empty, but what is the difference and is there one at all ?</p>
<p><span id="more-263"></span><br />
If we will look at the .NET String.cs we will see the next line:</p>
<pre class="c-sharp" name="code">
        public static readonly String Empty = "";
</pre>
<p>The above line can tell us that string.Empty is not a constant as we would like to believe but a readonly field.</p>
<p>The question is why, why static readonly and not a constant. The answer is in the same String.cs comments of the Empty field.</p>
<pre class="c-sharp" name="code">
        // The Empty constant holds the empty string value.
        //We need to call the String constructor so that the compiler doesn't mark this as a literal.
        //Marking this as a literal would mean that it doesn't show up as a field which we can access
        //from native.
</pre>
<p>Now, let&#8217;s make some test.</p>
<pre class="c-sharp" name="code">
            string EmptyValue = string.Empty;

            if (EmptyValue == "")
                // Output : Is Empty : 1
                Console.WriteLine("Is Empty : 1");

            if (EmptyValue.Length == 0)
                // Output : Is Empty : 2
                Console.WriteLine("Is Empty : 2");

            switch (EmptyValue)
            {
                case "":
                    {
                        // Output : Is Empty : 3
                        Console.WriteLine("Is Empty : 3");
                        break;
                    }
                 case string.Empty:
                    {
                        // Compilation error : A constant value is expected
                        Console.WriteLine("A constant value is expected");
                        break;
                    }
            }

            if (EmptyValue.Equals (""))
                // Output : Is Empty : 4
                Console.WriteLine("Is Empty : 4");

            if (string.IsNullOrEmpty(EmptyValue))
                // Output : Is Empty : 5
                Console.WriteLine("Is Empty : 5");
</pre>
<p>As we can see string.Empty and &#8220;&#8221; have the same behavior except the &#8220;switch&#8221; because string.Empty is not a constant.</p>
<p>And of course the most important question &#8211; is there a performance differences between the two ? The answer is &#8211; Yes, but minor.<br />
Lets see some results :</p>
<pre class="c-sharp" name="code">
           // Execution Time : 2144ms
            for (int n = 0; n < 100000000; n++)
            {
                if (TestValue == string.Empty)
                    t = 1; //"For test purposes only..."
            }

            // Execution Time : 2211ms
            for (int i = 0; i < 100000000; i++)
            {
                if (TestValue == "")
                    t = 2; //"For test purposes only..."
            }
</pre>
<p>We can see from the results that the comparison with string.Empty is a little bit faster but it's negligible.</p>
<p>One of the advantages of using "" is that it's in some cases it can be optimized by the compiler before the JIT. For example if you will run the same iteration while comparing ""==null the whole block will be removed by the optimizer.</p>
<p>So, use what ever you like, you'd probably won't see the difference.</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.2" /></div><div>Rating: 4.2/<strong>5</strong> (9 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F06%2Fstring-empty-versus-empty-quotes%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/06/string-empty-versus-empty-quotes/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>C# Protected Internal</title>
		<link>http://kossovsky.net/index.php/2009/06/cshar-protected-internal/</link>
		<comments>http://kossovsky.net/index.php/2009/06/cshar-protected-internal/#comments</comments>
		<pubDate>Sun, 28 Jun 2009 21:15:25 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[a3]]></category>
		<category><![CDATA[access modifier]]></category>
		<category><![CDATA[access modifiers]]></category>
		<category><![CDATA[c developers]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[c-sharp]]></category>
		<category><![CDATA[class a2]]></category>
		<category><![CDATA[Inheritance]]></category>
		<category><![CDATA[internal]]></category>
		<category><![CDATA[limited]]></category>
		<category><![CDATA[members]]></category>
		<category><![CDATA[namespace]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[private]]></category>
		<category><![CDATA[protected]]></category>
		<category><![CDATA[protected internal]]></category>
		<category><![CDATA[public]]></category>
		<category><![CDATA[public access]]></category>
		<category><![CDATA[public string]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=242</guid>
		<description><![CDATA[I&#8217;ve noticed that most of the c# developers i&#8217;am talking to, know exactly what &#8220;public&#8221;, &#8220;private&#8221;, &#8220;protected&#8221; and &#8220;internal&#8221; access modifiers mean and how to use them, but when it comes to &#8220;protected internal&#8221; they start guessing the answer and it&#8217;s never the right one. Well, let&#8217;s make some order in that. protected A protected [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.8" /></div><div>Rating: 4.8/<strong>5</strong> (15 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve noticed that most of the c# developers i&#8217;am talking to, know exactly what &#8220;public&#8221;, &#8220;private&#8221;, &#8220;protected&#8221; and &#8220;internal&#8221; access modifiers mean and how to use them, but when it comes to &#8220;protected internal&#8221; they start guessing the answer and it&#8217;s never the right one.</p>
<p><span id="more-242"></span></p>
<p>Well, let&#8217;s make some order in that.</p>
<p><strong>protected</strong><br />
A protected member is accessible <span style="text-decoration: underline;">within its class and by derived classes</span>.</p>
<p><strong>internal</strong><br />
Internal types or members are accessible <span style="text-decoration: underline;">only within files in the same assembly</span>.</p>
<p><strong>protected internal</strong><br />
Access is limited to the <span style="text-decoration: underline;">current assembly or types derived from the containing class</span>.<br />
* protected internal is the <span style="text-decoration: underline;">only access modifiers combination</span> allowed for a member or a type.</p>
<p>So, as we can see &#8220;protected internal&#8221; can be used in the same assembly or types derived from the containing class in any assembly.</p>
<p>It means that we can access a &#8220;protected internal&#8221; method by accessing any instance of it&#8217;s class in the same assembly, in any class in different assembly which derives from the class, but we won&#8217;t be able to access the method by accessing an instance of it&#8217;s class in different assembly.</p>
<pre class="c-sharp" name="code">// Assemby : A
namespace AssemblyA
{
    public class A
    {
        protected internal string SomeProtectedInternalMethod() {
            return "SomeValue";
        }
    }

    public class A2 : A
    {
        public string SomeMethod() {
            // We can access the method because
            // it's protected and inherited by A2
            return SomeProtectedInternalMethod();
        }
    }

    class A3 : A
    {
        public string SomeMethod()
        {
            A AI = new A();
            // We can access the method through an instance
            // of the class because it's internal
            return AI.SomeProtectedInternalMethod();
        }
    }
}</pre>
<pre class="c-sharp" name="code">// Assemby : B
using AssemblyA;
namespace AssemblyB
{
    class B : A
    {
        public string SomeMethod() {
            // We can access the method because
            // it's inherited by A2
            // despite the different assembly
            return SomeProtectedInternalMethod();
        }
    }

    class B2
    {
        public string SomeMethod()
        {
            A AI = new A();
            // We can't access the method
            // through the class instance
            // because it's different assembly
            return AI.SomeProtectedInternalMethod();
        }
    }
}</pre>
<p>So, if we will try to compile AssemblyB we&#8217;ll get an error in line 23 that says : <span style="color: #ff0000;">AssemblyA.A.SomeProtectedInternalMethod()&#8217; is inaccessible due to its protection level</span></p>
<p>I hope this explains once and for all the meaning of &#8220;protected internal&#8221; access modifier.</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.8" /></div><div>Rating: 4.8/<strong>5</strong> (15 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F06%2Fcshar-protected-internal%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/06/cshar-protected-internal/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>C# Inheritance Question</title>
		<link>http://kossovsky.net/index.php/2009/06/csharp-inheritance-question/</link>
		<comments>http://kossovsky.net/index.php/2009/06/csharp-inheritance-question/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 21:39:33 +0000</pubDate>
		<dc:creator>Xander</dc:creator>
				<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[C#]]></category>
		<category><![CDATA[Interview Questions]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tips & Tricks]]></category>
		<category><![CDATA[bug]]></category>
		<category><![CDATA[bugs]]></category>
		<category><![CDATA[c#.net]]></category>
		<category><![CDATA[fun]]></category>
		<category><![CDATA[Inheritance]]></category>
		<category><![CDATA[interview]]></category>
		<category><![CDATA[main string]]></category>
		<category><![CDATA[net c#]]></category>
		<category><![CDATA[Overloading]]></category>
		<category><![CDATA[public static string]]></category>
		<category><![CDATA[puzzles]]></category>
		<category><![CDATA[simple questions]]></category>
		<category><![CDATA[string result]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[visual c#]]></category>

		<guid isPermaLink="false">http://kossovsky.net/?p=191</guid>
		<description><![CDATA[The following are two simple questions related to C# inheritance. Please try to give an answer without executing the code, otherwise where is the fun part ? // Question #1 class Program { static void Main(string[] args) { int i = 13; string Result = B.Get(i); Console.WriteLine(Result); } } public class A { public static [...]<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.6" /></div><div>Rating: 4.6/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />]]></description>
			<content:encoded><![CDATA[<p>The following are two simple questions related to C# inheritance.<br />
Please try to give an answer without executing the code, otherwise where is the fun part ?<br />
<span id="more-191"></span></p>
<pre class="c-sharp" name="code">
    // Question #1
    class Program
    {
        static void Main(string[] args)
        {
            int i = 13;
            string Result = B.Get(i);
            Console.WriteLine(Result);
        }
    }

    public class A
    {
        public static string Get(int Value) {
            return "A";
        }
    }

    public class B : A
    {
        public static string Get(float Value)
        {
            return "B";
        }
    }
</pre>
<pre class="c-sharp" name="code">
    // Question #2
    class Program
    {
        static void Main(string[] args)
        {
            int i = 13;
            string Result = B.Get(i);
            Console.WriteLine(Result);
        }
    }

    public class B
    {
        public static string Get(float Value)
        {
            return "B";
        }

        public static string Get(int Value) {
            return "A";
        }
    }
</pre>
<p>What will be the result of the above code parts ?</p>
<br /><div><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx.php?value=4.6" /></div><div>Rating: 4.6/<strong>5</strong> (5 votes cast)</div><br /><a target="_blank" href="http://www.gdstarrating.com/"><img src="http://kossovsky.net/wp-content/plugins/gd-star-rating/gfx/powered.png" border="0" width="80" height="15" /></a><br />
<p class="FacebookLikeButton"><fb:like href="http%3A%2F%2Fkossovsky.net%2Findex.php%2F2009%2F06%2Fcsharp-inheritance-question%2F" layout="standard" show_faces="false" width="450" action="like" colorscheme="light"></fb:like></p>
]]></content:encoded>
			<wfw:commentRss>http://kossovsky.net/index.php/2009/06/csharp-inheritance-question/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
	</channel>
</rss>

