C# Trivia Quiz Part B - Answers

Some nice answers in the comments to the quiz . I'll touch on some of them. Probably.

I think I'll put all the remaining questions into a jumbo part 3.

Language Details

1) Java has a >>> operator. C# doesn't. Why?

Java needs that weird operator because it doesn't have unsigned types, but C# does.

2) When can a readonly field be assigned to?

Readonly fields can be assigned with initializers or in the appropriate constructor (static or instance, depending on the the field flavor).

C# and the Runtime

3) What does [FieldOffset(12)] do?

When placed on a field in a structure, it says that when marshalling the structure (ie creating an unmanaged version), this field should be offset 12 bytes from the beginning of the structure. It's most typically used when you have to deal with nasty C/C++ unions.

C# and other languages

4) Perl and C# are alike because...

They both have foreach.

Maurits noted that they both have regexes and anonymous subroutines (closures/delegates). Strictly speaking, regexes aren't part of C# but rather are part of the BCL, and I didn't think of the delegates one, so both of those answers are wrong.

Real Trivia

5) How many people were in the Visual C# Product Unit when C# was first disclosed?

JamesCurran got the right answer for the entirely wrong reason. He advocated C# usage going back to the early 1990s, and while there were some discussions around that back then, they didn't use the C# name, and didn't get disclosed. But he did get the right answer - at least, the overly pedantic answer, which was the one that I was planning on using.

The answer is zero, for the simple reason that everybody working on the team was part of the C++ team at the time, and the C# product unit didn't come around until (IIRC) sometime that fall.

The real answer to the question, "how many people worked full-time on the first version on C# before that?", is 15 +- 2. Ish.

6) Explain the history of the 'hort' data type, and how it relates to C#...

I had intended to include the nice story here, but alert reader Mark Steward found where I had talked about it before. So go read the "story" section of that post.

Power Users

7) What do the following people have in common, and how are each of them related to C#?
James Newkirk
Peter Solich
Lutz Roeder

I was surprised that nobody got this one. There are two possible answers. The right one is that each of them have been deeply involved with a very useful C# utility:

James Newkirk - NUnit

Peter Solich - CLR Profiler

Lutz Roeder - .NET Reflector

So, if you ever see these guys, thank them.

Peter also lent a considerable amount of expertise to the C# language design process during his tenure on the design team.

Ancient History

8) In his "Introduction to C#" talk at the first .NET PDC, Joe Nalewabau started his talk off by saying that his manager would upgrade him to first class on his trip back home if all his demos worked. Was this the truth, or was it a clever presentation device?

No and Yes. Yes and No.

Take your pick.

In a spendidly inspired bit of presentation wizardry, Joe came out on stage and hooked the audience on his story. All of us in that hall wanted his demos to work. Masterful.

And completely fabricated.

But... His manager was also there in the hall, and agreed to upgrade him on the trip back for doing such a great presentation.

9) In this presentation, Joe made a joke about the PDC speaker shirts. What sport did his joke refer to?

Bowling.

Speaker shirts are one of the anti-perks of speaking at a conference. You get a shirt (or, if you're lucky, two shirts) to get you through 4 or 5 days at a conference, and you get to be noticebly poorly-dressed and sweaty (for they are often polyester) for that entire time. I've gotten perhaps 35 or 40 shirts from the talks that I've done, and I currently own 3 or 4 of them.

But those PDC shirts set a new standard.