C#中class类的private
红色代码部分是什么意思?
不要那一段代码也能运行,也不报错,但是我看他们都加了这段代码
新手求问红色那段代表什么
class count
{
private double x;
private double y;
public count(double m,double n)
{
x = m;
y = n;
}
public double Distance(double x, double y)
{
double dis;
dis =Math.Sqrt((x+1)*(x+1)+(y+1)*(y+1));
return dis;
}
}