C
C#2y ago
wcasa

Some namespace and class questions..

namespace Cool
{
class VeryCool
{
static void main(string[] args)
{
namespace Console
{
WriteLine("Why isnt it possible?");
}
}
}
}
namespace Cool
{
class VeryCool
{
static void main(string[] args)
{
namespace Console
{
WriteLine("Why isnt it possible?");
}
}
}
}
4 Replies
wcasa
wcasaOP2y ago
in my logic, following code should be smth like:
Cool.Console.WriteLine("...");
Cool.Console.WriteLine("...");
but it doesnt work, why?
phaseshift
phaseshift2y ago
you can't have namespaces inside classes
ero
ero2y ago
and much less inside methods
wcasa
wcasaOP2y ago
!solved
Want results from more Discord servers?
Add your server