110,538
社区成员
发帖
与我相关
我的任务
分享
public override bool Equals(object x)
{
if (!(x is car))
{
return false;
}
else
{
return this==x as car;
}
}
public override int GetHashCode()
{
return base.GetHashCode();
}
if (acar.Equals(bcar))
{
Console.Write(acar.GetHashCode()+"----"+bcar.GetHashCode());
}
public struct Point {
public int x;
public int y;
//other methods
public override int GetHashCode() {
return x ^ y;
}
}