contestada

If you have defined a class SavingsAccount with a public static method get Number Of Accounts, and created a Savings Account object referenced by the variable account20, which of the following will call the get Number Of Accounts method?A. get Number Of Accounts.B. savings Account get Number Of Accounts.C. account 20.get Number Of Accounts.D. none of these.

Respuesta :

Lanuel

Answer:

C. account 20.get Number Of Accounts.

Explanation:

Using the command;

"account 20.get Number Of Accounts." Or

"numAccounts=SavingsAccount.numberOfAccounts;" would call the get Number Of Accounts method.

Answer:

numAccounts = SavingsAccount.numberOfAccounts or you use account20.getnumberofaccounts

Explanation:

This is a Java question , our task here is to call the get number of accounts which we do by imputing the code above .

RELAXING NOICE
Relax