Click here to Skip to main content
14,603,215 members
Rate this:
Please Sign up or sign in to vote.
See more:
someone just discribe me what i have to do i cant understand the question


Write a program that uses class members and instance members to manipulate different
bank accounts. Bank accounts can be of two types. In one type the initial amount is Rs
25000 and in other type the initial amount is Rs 45000. Use a class field to keep count of
no. of account opened. Common rate of interest is 8.75% p.a .The interest is to be
calculated for one year and then balance is to be updated.


What I have tried:

i have not tried becuse iam confused please some one explain me what i have to do step by step
Posted
Updated 24-Jul-20 23:37pm
Comments
Richard MacCutchan 25-Jul-20 4:56am
   
The same answer as your other two questions: Learn and try for yourself.
Rate this:
Please Sign up or sign in to vote.

Solution 1

First create the classes: you want two types, probably derived from a third abstract base class called Account. One type when constructed starts with 25,000; the other with 45,000.
Add a member method to the Account class which calculates the interest and updates teh balance.

This isn't complicated - it's pretty basic stuff as far as classes go - so re-read your recent course notes (and the relevant course book chapters if you have one) and think about the task. It's probably less than a dozen lines of code to set this up - and probably double that to test that it works! :laugh:

Give it a try, and see how far you can get.
   
Rate this:
Please Sign up or sign in to vote.

Solution 2

Go to The Java™ Tutorials[^] where you will find good explanations and samples of classes and their usage.
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100