[[Explanation of the program deleted - replace this with a summary of your scenario]] Enter which option you would prefer: 1 Week 1 Linear: $2193.18, Exponential: $0.01 Week 2 Linear: $4386.36, Exponential: $0.02 Week 3 Linear: $6579.54, Exponential: $0.04 Week 4 Linear: $8772.72, Exponential: $0.08 Week 5 Linear: $10965.90, Exponential: $0.16 Week 6 Linear: $13159.08, Exponential: $0.32 Week 7 Linear: $15352.26, Exponential: $0.64 Week 8 Linear: $17545.44, Exponential: $1.28 Week 9 Linear: $19738.62, Exponential: $2.56 Week 10 Linear: $21931.80, Exponential: $5.12 Week 11 Linear: $24124.98, Exponential: $10.24 Week 12 Linear: $26318.16, Exponential: $20.48 Week 13 Linear: $28511.34, Exponential: $40.96 Week 14 Linear: $30704.52, Exponential: $81.92 Week 15 Linear: $32897.70, Exponential: $163.84 Week 16 Linear: $35090.88, Exponential: $327.68 Week 17 Linear: $37284.06, Exponential: $655.36 Week 18 Linear: $39477.24, Exponential: $1310.72 Week 19 Linear: $41670.41, Exponential: $2621.44 Week 20 Linear: $43863.59, Exponential: $5242.88 Week 21 Linear: $46056.77, Exponential: $10485.76 Week 22 Linear: $48249.95, Exponential: $20971.52 Week 23 Linear: $50443.13, Exponential: $41943.04 Week 24 Linear: $52636.31, Exponential: $83886.08 Your uncle dies after 32 weeks so you [[Update language for your scenario]] got unlucky and missed out on $21404654.73. Do you want to play again? (1 for yes) or (0 for no) 1 [[Explanation of the program deleted - replace this with a summary of your scenario]] Enter which option you would prefer: 1 Week 1 Linear: $1873.25, Exponential: $0.01 Week 2 Linear: $3746.50, Exponential: $0.02 Week 3 Linear: $5619.75, Exponential: $0.04 Week 4 Linear: $7492.99, Exponential: $0.08 Week 5 Linear: $9366.24, Exponential: $0.16 Week 6 Linear: $11239.49, Exponential: $0.32 Week 7 Linear: $13112.74, Exponential: $0.64 Week 8 Linear: $14985.99, Exponential: $1.28 Week 9 Linear: $16859.24, Exponential: $2.56 Week 10 Linear: $18732.49, Exponential: $5.12 Week 11 Linear: $20605.74, Exponential: $10.24 Week 12 Linear: $22478.98, Exponential: $20.48 Week 13 Linear: $24352.23, Exponential: $40.96 Your uncle dies after 14 weeks so you [[Update language for your scenario]] got lucky and ended up with an extra $26143.56. Do you want to play again? (1 for yes) or (0 for no) 0## Just For Fun Feel free to add additional features to make the program more interesting but be sure to complete all of the requirements first. If you have ideas to improve the program that don't comply completely with the specified requirements, consult with your instructor first. ## Notes * You must place your program in a class called `Lab4`. * You must place your name and a short description of your program in a comment at the top of the file. * You must use meaningful variable names and indentation appropriate to the "good" style demonstrated in class. * To get the output to format with two decimal places, you can use the following code: ``` System.out.format("Week %2d Linear: $%.2f\n", numberOfWeeks, linearAmount); ``` * To generate a random number between 0.0 and 1.0 you can use call the following method: `Math.random()`. ## Acknowledgement This laboratory assignment was developed by Dr. Derek Riley.
Lab
4
Start Now
See your professor's instructions for details on submission guidelines and due dates.
Friday, 21-Sep-2018 08:44:27 EDT