Write an application that calculates and displays the amount of money a user would have if his or her money could be invested at 5 % interest for one year. Create a method that prompts the user for the starting value of the investment and returns to the calling program. Call a separate method to do the calculation, and return the result to be displayed. Save the program as Interest.java

-(A) Create a class named Sandwich. Data fields include a String for the main ingredient (such as tuna) a String for bread type (such as wheat) and a double for price (such as 4.99). Include methods to get and set clause for each of these fields. Save the class as Sandwich.java.

- (B)Create an application named TestSandwich that instantiates on Sandwich object and demonstrates the use of the set and get methods. Save this application as TestSandwich.java

Note: In the Sandwich class, add a constructor that initially sets the main ingredient to "Turkey", the bread type to "Rye", and the price to 5.99.

In the TestSandwich class, add a secondary sandwich object that demonstrates that the constructor works by displaying the Sandwich's initial values.

Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.