110,536
社区成员
发帖
与我相关
我的任务
分享
namespace LevelOne
{
// name "NameThree" defined
namespace LevelTwo
{
// name "NameThree" defined
}
}
namespace LevelOne
{
using LevelTwo;
namespace LevelTwo
{
// name "NameTwo" defined
}
}
using System;
using System.Collections.Generic;
using System.Text;
namespace MySpace
{
public class Hello
{
public Hello()
{
}
public void Say()
{
Console.WriteLine("Hello,World");
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
using MySpace;
namespace Ex_NameSpace
{
class Program
{
static void Main(string[] args)
{
Hello h = new Hello();
h.Say();
Console.ReadLine();
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
namespace Ex_NameSpace
{
class Program
{
static void Main(string[] args)
{
MySpace.Hello h = new MySpace.Hello();
h.Say();
Console.ReadLine();
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
namespace MySpace
{
public class Hello
{
public Hello()
{
}
public void Say()
{
Console.WriteLine("我有写数据的功能");
}
public void Write()
{
Console.WriteLine("我可以写数据");
}
}
}
namespace MySpace.ReadOnly{
public class Hello
{
public Hello()
{
}
public void Say()
{
Console.WriteLine("我只能读取,不能写");
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
using MySpace;
using MySpace.ReadOnly;
namespace Ex_NameSpace
{
class Program
{
static void Main(string[] args)
{
Hello h = new Hello();
h.Say();
Console.ReadLine();
}
}
}
using System;
using System.Collections.Generic;
using System.Text;
namespace Ex_NameSpace
{
class Program
{
static void Main(string[] args)
{
MySpace.Hello h = new MySpace.Hello();
h.Say();
MySpace.ReadOnly.Hello hread = new MySpace.ReadOnly.Hello();
hread.Say();
Console.ReadLine();
}
}
}