急需c#编程题。谢谢你们了
怎么用c#编写一道用正方行类。四边都一样只用一个宽de属性,单参构造函数,二个方法计算周长和面积
class zhengfangxing
{
private int bianchang;
public zhengfangxing(int bc)
{
this.biangchang=bc;
}
public int zhouchang()
{
return bianchang*4;
}
public int mianji()
{
return bianchang*bianchang;
}
}