How do I use an int variable as a boolean.
Code:
private int choose;
System.out.println("Do you wish to apply for the loan \n1 Yes n\2 No");
choose = scanner.nextInt();
if (choose = 1)
System.out.println("You have applied for the loan");
else
System.out.println("Your application have been cancelled.");
Comment