C# 4.0 - New Feature I Like Most
String.IsNullOrWhiteSpace
Previous version of C# contain method String.IsNullOrEmpty which checks whether string is empty or null. If String only contain white spaces (it's also a case of empty string) you will be required to add an additional trim() function to handle it. But if you will use trim() on an null string, it will throw exception so you will be required to write few lines of code for it. But new function in string class
The new String.IsNullOrWhiteSpace method indicates whether
a string is null, empty, or consists only of white-space characters.