All pastes #415077 Raw Edit

Stuff

public text v1 · immutable
#415077 ·published 2007-03-29 14:45 UTC
rendered paste body
import java.util.*; // Needed for Keyboard
import javax.swing.*; // Needed for JOpionPane

public class AcmeBankFINAL

{
	public static void main(String[] args)

	{
			
	double LoanAmount = 0.0;
	double AnInRate = 0.0;
	int NumYears = 0;
	String RepaymentMethod = "Monthly";
	boolean OzCitzen = true;
	String ExistingAnc = "No";
	int OverFifty = 40;
	

		Scanner Keyboard = new Scanner(System.in); //Introducing Scanner naming string Keyboard
		
		String temp;
		
	temp = JOptionPane.showInputDialog("Requested Loan Amount");
	LoanAmount = Double.parseDouble(temp); 
				
		//System.out.print("Requested Loan Amount: ");	
		//LoanAmount = Keyboard.nextDouble( );
	
	temp = JOptionPane.showInputDialog("Annual Interest rate");
	AnInRate = Double.parseDouble(temp);
		
		//System.out.print("Annual Interest Rate: ");
		//AnInRate = Keyboard.nextDouble( );
	
	temp = JOptionPane.showInputDialog("Number of years over which the loan will be paid in");
	NumYears = Integer.parseInt(temp);
	
		//System.out.print("The number of years over which the loan will be paid in: ");
		//NumYears = Keyboard.nextInt( );
	
	temp = JOptionPane.showInputDialog("Replayment method, either Quarterly, Monthly or Fortnightly");
	
		//RepaymentMethod = Keyboard.nextLine( );
		//System.out.print("Replayment method, either Quarterly = Q, Monthly = M or Fortnightly = F: ");
		//RepaymentMethod = Keyboard.nextLine( );
	
	 temp = JOptionPane.showInputDialog("Do you have an accounting account, Yes Or No"); //String

		//System.out.print("Do you have an accounting account, Yes Or No: ");
		//ExistingAnc = Keyboard.nextLine( );

	 temp = JOptionPane.showInputDialog("Are you an Australian Citzen, True or False"); //Boolean
	 			
		//System.out.print("Are you an Australian Citzen, True or False: ");
		//OzCitzen = Keyboard.nextBoolean( );
	
	 temp = JOptionPane.showInputDialog("How old are you? In Number format"); //String
	
		//System.out.print("How old are you? (In Number format): ");
		//Overfifty = Keyboard.nextInt( );
	
//Special Characteristics
	
	if(ExistingAnc.equals("no"))
	{
	}
	else
	
	JOptionPane.showMessageDialog(null, "Existing Account: Sorry you are not eligible for a loan"); //Message to show loan not eligible
	
		//System.out.println("Existing Account: Sorry you are not eligible for a loan");
	
	if(OzCitzen == true)
	{
	}
	else

	JOptionPane.showMessageDialog(null, "Existing Account: Sorry you are not eligible for a loan");	//Message to show loan not eligible
	
		//System.out.println("Australian Citizen: Sorry you are not eligible for a loan");
	
	if(OverFifty <= 50)
	{
	}
	else
	
	JOptionPane.showMessageDialog(null, "Existing Account: Sorry you are not eligible for a loan");	//Message to show loan not eligible
	
		//System.out.println("Age: Sorry you are not eligible for a loan");
	
	
//Output all Results
	
	}
	
	
	
}