我的方案汇编了起来,但是,如果开端,它永远不会脱离 lo,并且说阵列太大。 这是我的法典:
public class ComparableArray
{
public static void Main()
{
taxpayer[] taxArray = new taxpayer[5];
int x;
for(x= 0; x < taxArray.Length; ++x)
taxArray[x] = new taxpayer();
Console.Write("Enter Social Security Number for taxpayer {0}: ", x+1);
taxArray[x].SSN = Console.ReadLine();
Console.Write("Enter gross income for taxpayer {0}: ", x+1);
taxArray[x].Income = Convert.ToDouble(Console.ReadLine());
taxpayer.getRates();
x++;
}
}
I m not sure what I m doing wrong, I would appreciate any help.