in

B# .NET Technical Community Homepage

Bart De Smet's online technical community
All Tags » C# 2.0 (RSS)

Browse by Tags

  • Answers to C# Quiz - Fun with System.Xml

    Answers to the C# Quiz - Fun with System.Xml . Here's a quick refresh of the problem: Copy Code 1 using System; 2 using System.Xml; 3 4 class Program 5 { 6 static void Main() 7 { 8 new Bar < int > ().CreateBar < double > ( " Bart " ).CreateBar < long > ( " DeSmet "...
    Posted to B# .NET Blog (Weblog) by bart on 04-18-2007
  • C# Quiz - Fun with System.Xml

    A simple quiz today; it's rather a System.Xml debugging job. With this I've said too much already. Here it is: Copy Code 1 using System; 2 using System.Xml; 3 4 class Program 5 { 6 static void Main() 7 { 8 new Bar < int > ().CreateBar < double > ( " Bart " ).CreateBar < long...
    Posted to B# .NET Blog (Weblog) by bart on 04-12-2007
  • Introducing PLINQ

    On the last edition of Developer & IT Pro Days in Belgium last week, Raj Pai - program manager on the C# team at MS Corp - delivered the first public demo of PLINQ aka Parallel LINQ . Let's have a quick look... By now, every blog reader should be familiar with the concept of LINQ, the Language INtegrated...
    Posted to B# .NET Blog (Weblog) by bart on 04-04-2007
  • Answers to C# Quiz - Need for speed

    You can find the original quiz over here . There have been lots of great answers, thanks to all readers! The bottom line however is that one should be careful when doing performance optimizations; in much cases the code doesn't become cleaner (even the opposite). One shouldn't trade design guidelines...
    Posted to B# .NET Blog (Weblog) by bart on 03-13-2007
  • C# 2.0 iterators revisited - The Pascal triangle

    Last week, I introduced C# 2.0 to a few academic people who had prior exposure to C, C++ and Java. Does language matter is an often heard question. Well, in the world of .NET, the importance of language choice has somewhat blurred but richness of languages still is a great decision factor, certainly...
    Posted to B# .NET Blog (Weblog) by bart on 02-28-2007
  • C# Quiz - Need for speed

    This quiz was derived from an old piece of code I reviewed for a student's project somewhere in the past. Actually, I was doing some perf-related work today, so I thought it might be useful to have a little quiz around this. Below is the code (reduced in size) of a matrix implementation in C#. Using...
    Posted to B# .NET Blog (Weblog) by bart on 02-27-2007
  • C# Quiz - call versus callvirt

    A little different quiz approach today; starting from IL :-). The question is pretty simple: when does the C# compiler emit a call instruction instead of a callvirt instruction? A little sample to illustrate the non-trivial character of this question: 1 class Call 2 { 3 static void Main() 4 { 5 C c ...
    Posted to B# .NET Blog (Weblog) by bart on 02-27-2007
  • Virtual vs. non-virtual method calls from a perf perspective

    Last week, I was doing an introduction session on C# for students with a Java background. There were quite some interesting discussions around the why and how of properties, indexers, operator overloads, events, delegates, attributes, etc compared to "equivalents" in Java. I won't repeat this discussion...
    Posted to B# .NET Blog (Weblog) by bart on 02-26-2007
  • Windows Vista - Introducing TxF in C# (part 3) - CreateFileTransacted demo

    In November last year, I blogged about TxF: Windows Vista - Introducing TxF in C# (part 1) - Transacted file delete Windows Vista - Introducing TxF in C# (part 2) - Using System.Transactions and the DTC A few days ago I received a mail from a reader of my blog who had an issue with a similar CreateFileTransacted...
    Posted to B# .NET Blog (Weblog) by bart on 02-21-2007
  • Answers to C# Quiz - "Something weird"

    I told you guys it was trivial :-). First of all, there's nothing wrong with the code: 1 class Weird 2 { 3 static void Main() 4 { 5 int i = 1 ; 6 for (i = 0 ; i < 100 ; i ++ ) 7 { 8 System.Console.Write( ' . ' ); 9 } while (i <= 100 ); 10 } 11 } Why? C# doesn't care about spacing; it could have...
    Posted to B# .NET Blog (Weblog) by bart on 02-19-2007
Page 1 of 8 (79 items) 1 2 3 4 5 Next > ... Last ยป
Powered by Community Server (Non-Commercial Edition), by Telligent Systems