javaScript和C#语法对比

//javaScript中类的定义
Class1=func()//类的定义
{
    this.name='';//类的私有变量
}
Class1.prototype.Method1=func()//类class共有方法
{
    var a='';//方法Method1的私有变量
}
//C#中类的定义
public class Class1
{
    private string name='';//类的私有变量
    public void Method1()//共有方法的定义
    {
        string a="";//方法的私有变量
    }
}
原文地址:https://www.cnblogs.com/kuailewangzi1212/p/1187855.html