I have overcome some of my confusion and come up with this;
import javax.swing.JOptionPane;
public class FixedStartingBankBalanceAccount
{
public static void main(String[] args)
{
double balance;
BankAccount myFirstAccount = new BankAccount(5000);
myFirstAccount.withdraw(200);
System.out.println(myFirstAccount.getBalance());
JOptionPane.showMessageDialog(null, "myFirstAccount contains:" + balance);
}
}
I am still a little confused on whether I need to declare the variables such as balance or is this done in the BankAccount file??