public class Account
{
static int accountNum;
static int nextAccountNum = 112200;
static double balance;
public static void main(String args[])
{
Account checkingAccount = new Account(1500.00);
Account savingAccount = new Account(1000.00);
Account moneyMarketAccount = new Account(500.00);
checkingAccount.getAccountNumber();
savingAccount.getAccountNumber();
moneyMarketAccount.getAccountNumber();
}
public Account(double bal)
{
balance = bal;
accountNum = nextAccountNum;
nextAccountNum++;
}
}
每次我运行它时,我都没有得到任何返回变量。我所看到的只是过程完成的文本。寻求帮助