27
HashSet<string> is not sorted by design. If you want to sort the items once (~not often) then you can use OrderBy LINQ method (because HashSet<string> implements IEnumerable<string>): hs.OrderBy(s => s);
If you need sorted hashset then you can use SortedDictionary class - just use some dummy type (i.e. bool) for TValue generic parameter.
The SortedSet class is not available in .NET 3.5.