错误 1 类,结构或接口成员声明中的标记"{"无效 5
usingSystem;usingSystem.Collections.Generic;usingSystem.Linq;usingSystem.Text;namespa...
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace _1_5
{
class Employee
{
private int id;
public int id;
{
get {return id ;}
set {id=value;}
}
private string name;
public string Name
{
get{return name;}
set{name=value;}
}
private bool marry;
private bool Marry;
{
get{return marry;}
set{marry=value;}
}
private decimal salary;
public decimal Salary
{
get{return salary;}
set{salary=value;}
}
public Employee(int id,string name,bool marry,decimal salary)
{
this.id=id;
this.name=name;
this.marry=marry;
this.salary=salary;
}
}
第三个“{”无效 展开
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace _1_5
{
class Employee
{
private int id;
public int id;
{
get {return id ;}
set {id=value;}
}
private string name;
public string Name
{
get{return name;}
set{name=value;}
}
private bool marry;
private bool Marry;
{
get{return marry;}
set{marry=value;}
}
private decimal salary;
public decimal Salary
{
get{return salary;}
set{salary=value;}
}
public Employee(int id,string name,bool marry,decimal salary)
{
this.id=id;
this.name=name;
this.marry=marry;
this.salary=salary;
}
}
第三个“{”无效 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询