Engineering
Engineering, 26.11.2019 02:31, Camill0310

Create a class named accountsavings. this class has a static double variable which stores the annual interest rate for all account holders. the name of variable is annualinterestrate. the class also has another double variable named savingsbalance which stores balance for current account. a. write a constructor to create an account with specified balance. add a validation whether the balance is greater than 0.0. if it is less than 0.0 then throw an exception. b. write a non-static calculatemonthlyinterest method to calculate the monthly interest by multiplying the savingsbalance by annualinterestrate divided by 12 – the interest should be added to savingsbalance. c. write a static method named modifyinterestrate to set the annual interest rate. add a validation whether the rate is greater than equal to 0.0 and less than or equal 1.0. otherwise, throw an exception. d. write a tostring method which returns savingsbalance in a string format. after that, create accountsavingstest class. create two objects from the class accountsavings with balances $2000.00 and $3000.00. then, set the interest rate to 4%, then calculate the monthly interest rate for each 12 months for each object and print the new balances with tostring method for each object. upload accountsavings. java and accountsavingstest. java.

answer
Answers: 3

Other questions on the subject: Engineering

image
Engineering, 04.07.2019 18:10, jojoangelique13
The flow rate of air through a through a pipe is 0.02 m5/s. a pitot static tube is placed in the flow. the radius of the pitot static tube is 1 mm. assuming the flow to be steady and the air to be at 300k, calculate the difference in total and static pressure if the diameter of the pipe is: (a) d 0.1 m d 0.05 m (c) d 0.01 m
Answers: 2
image
Engineering, 04.07.2019 18:20, 1230bering
Select any two (2) areas of applications of chain-drive. (clo4) a)-permanent lubrication necessary b)-hydraulic forklift truck operation c)-rigging and heavy moving materials d)-relatively high maintenance costs e)-costlier than belt drives
Answers: 2
image
Engineering, 04.07.2019 19:10, Destinationz
Asteam is contained in a rigid tank with a volume of 1 m3. initially, the pressure and temperature are 7 bar and 500 oc, respectively. the temperature drops due to cooling process. determine: (1) the temperature at which condensation begins in °c, (2) the fraction of the total mass that has condensed when the pressure decreased to 0.5 bar. (3) the volume in m3 occupied by saturated liquid at the final state?
Answers: 3
image
Engineering, 04.07.2019 19:10, ultimateapes
When subject to a steady load (within elastic range) over a long period of time, what is the major difference in material behavoir between steel and plastic?
Answers: 2
Do you know the correct answer?
Create a class named accountsavings. this class has a static double variable which stores the annual...

Questions in other subjects: