├── README.md └── Implementing Object Oriented Concepts /README.md: -------------------------------------------------------------------------------- 1 | # BANK CODE USING JAVA 2 | It has all JAVA OOPS concepts 3 | -------------------------------------------------------------------------------- /Implementing Object Oriented Concepts: -------------------------------------------------------------------------------- 1 | Aim 2 | Creating an Account class which has deposit() and withdraw() methods 3 | Algorithm : 4 | Step 1: Start the Program 5 | Step 2: Create Class 6 | Step 3: Declare the Input and Output Variables 7 | Step 4: Create object and access the method 8 | Step 5: Implement it with return type and without parameter list 9 | Step 6: Implement it with return type and with parameter list 10 | Step 7: Implement the constructor by creating classes and objects 11 | Program : 12 | class Account 13 | { 14 | int acc_no; 15 | String name; 16 | float amount; 17 | //Method to initialize object 18 | void insert(int a,String n,float amt) 19 | { 20 | acc_no=a; 21 | name=n; 22 | amount=amt; 23 | } 24 | void deposit(float amt) 25 | { 26 | 27 | amount=amount+amt; 28 | System.out.println(amt+" deposited"); 29 | } 30 | //withdraw method 31 | void withdraw(float amt) 32 | { 33 | if(amount