
The following code was already given.
Console.java – import java.util.Scanner;
public class Console {
private static Scanner sc = newScanner(System.in);
public static String getLine(String prompt){
System.out.print(prompt);
String s =sc.nextLine(); // readthe whole line
return s;}
public static String getString(String prompt){
System.out.print(prompt);
String s =sc.next(); // read thefirst string on the line
sc.nextLine(); // discard the rest of the line
return s;}
public static int getInt(String prompt) {
int i = 0; booleanisValid = false;
while (!isValid){
System.out.print(prompt);
if (sc.hasNextInt()) {
i = sc.nextInt(); isValid = true;
} else {
System.out.println(“Error!
PayPal Gateway not configured
PayPal Gateway not configured