import java.util.Scanner;
public class BankAccount{
public static void main(String[] args){
Scanner reader = new Scanner(System.in);
BankAccount account1 = new BankAccount();
String response1, response2;
System.out.print("Do you already have an account? ");
response1 = reader.nextLine();
if(response1.compareTo("yes") == 0){
System.out.print("What is your account name? ");
account1.setName(reader.nextLine());
reader.nextLine();
system.out.print("What is your balance? ");
AccountBalance = reader.nextDouble();
account1.setBalance(reader.nextDouble());
}else{
system.out.print("Would you like to create an account? ");
response2 = reader.nextLine();
if(response2.compareTo("yes") == 0){
system.out.print("What is your account name? ");
account1.setName(reader.nextLine());
reader.nextLine();
system.out.print("What is your balance? ");
account1.setBalance(reader.nextDouble());
}else{
system.out.print("Thank You for choosing Bank of Computer Science");
}
system.out.print("How much would you like to deposit into your account? ");
account1.deposit(reader.nextDouble());
system.out.print("How much would you like to withdrawl from your account? ");
account1.withdraw(reader.nextDouble());
if(Balance <= 0)
system.out.print("The following transaction could not be completed");
system.out.print("Bank Of Computer Science \n" + "Founded in 2007 \n" + "\n" + "\n" +
"The Account of " + account1.getNane() + " has a balance of $" + account1.getBalance() + ".");
}
}
}