In an ASP.NET C# application, I noticed in order to use Regex and StringBuilder, I had to put both
using System.Text;
using System.Text.RegularExpressions;
Regex is defined in System.Text.RegularExpressionsStringBuilder is defined in System.TextYou need to include both namespaces for these two types to be in scope. Including a namespace A.B doesn't automatically include a contained namespace A.B.C. If this were the case, nested namespaces would be of limited use.