C# Tutorial

An Interactive C# Tutorial, Covering Mainly C# .NET 2.0, C# ADO.NET, C# Threading, C# ASP.NET, and C# Syntax

C# Tutorial


 

Entries Tagged as 'Generics'

C# Generics Are Awesome!!!

May 8th, 2008 · No Comments

C# generics are one of the greatest features of c# in my opinion.  They are so great because they give you:
 Type Safe Collections
In the old arraylist, you had code like this:
ArrayList a = new ArrayList();
a.Add(new object());
a.Add(new Foo());
a.Add(1);
if you then did code to iterate through the list, you would need to add tons of code to […]

[Read more →]

Tags: Generics