@@ -0,0 +1,2280 @@
+package thirty_days_of_code;%0D%0A%0D%0Aimport java.util.Scanner;%0D%0A%0D%0A/*%0D%0A * Problem Statement%0D%0A * %0D%0A * Practice how to do arithmetic with code in this challenge! If given the meal%0D%0A * price, tip percentage, and tax percentage, we can find the final price of a%0D%0A * meal.%0D%0A * %0D%0A * In many of these challenges, you will need to read input from stdin (standard%0D%0A * input) and write your output in stdout (standard output). Different%0D%0A * programming languages provide different ways to handle input and output.%0D%0A * %0D%0A * In Java, one way to take input from stdin is to use the Scanner class and%0D%0A * read in from System.in. In other words, Java's Scanner class allows us to get%0D%0A * information from the user/outside world by reading in from System.in.%0D%0A * %0D%0A * In this problem, we read as input the original price of the meal, tip%0D%0A * percentage, and tax percentage.%0D%0A * %0D%0A * Good luck!%0D%0A * %0D%0A * Input Format%0D%0A * %0D%0A * Three numbers, (M, T, and X), each on separate lines:%0D%0A * %0D%0A * M will be a double representing the original price of the meal.%0D%0A * %0D%0A * T will be a integer representing the percentage that the customer wants to%0D%0A * tip based off of the original price of the meal.%0D%0A * %0D%0A * X will be an integer representing the tax percentage that the customer has to%0D%0A * pay based off of the original price of the meal.%0D%0A * %0D%0A * Output Format%0D%0A * %0D%0A * A string stating...%0D%0A * %0D%0A * The final price of the meal is $-.%0D%0A * where the final price of the meal is substituted for the dash. The price%0D%0A * should be rounded to the nearest integer (dollar) - the code for rounding has%0D%0A * already been added in the editor if you are coding in Java.%0D%0A * %0D%0A * Sample Input%0D%0A * %0D%0A * 12.00%0D%0A * 20%0D%0A * 8%0D%0A * Sample Output%0D%0A * %0D%0A * The final price of the meal is $15.%0D%0A */%0D%0Apublic class Arithmetic %7B%0D%0A%0D%0A    public static void main(String%5B%5D args) %7B%0D%0A        %0D%0A        Scanner sc = new Scanner(System.in);%0D%0A        double M = sc.nextDouble(); // original meal price%0D%0A        int T = sc.nextInt(); // tip percentage%0D%0A        int X = sc.nextInt(); // tax percentage%0D%0A%0D%0A        double tip = (M * T) / 100;%0D%0A        double tax = (M * X) / 100;%0D%0A        int total = (int) Math.round(M + tip + tax);%0D%0A      %0D%0A        System.out.println(%22The final price of the meal is $%22 + total + %22.%22);%0D%0A        sc.close();%0D%0A    %7D%0D%0A%7D

Add Arithmetic