0
Java code for Atm machine
A costomer wants the opportunity to delete, enter and cancel an amount in an atm
2 Réponses
+ 5
hey Afft why not show your code and state the specific problem that will help more
0
This shouldn't be too hard if it's just for training - just implement the methods as needed (since it's not clear what you want to do)
import java.util.Scanner;
public class ATM {
static Scanner sc;
static String amount;
static String customerResponse = null;
public static void main(String[] args) {
System.out.println("enter amount:");
sc.nextLine();
System.out.println("delete, enter or cancel?") ;
sc.nextLine();
switch (customerResponse) {
case "delete":
delete();
break;
case "enter:
enter();
break;
case "cancel":
cancel();
break;
default:
System.out.println("insert enter delete cancel");
}
}
public static void delete() {
}
public static void enter () {
}
public static void cancel() {
}
}