Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class YardGreening {
- public static void main(String[] args) {
- Scanner scanner = new Scanner(System.in);
- double meters = Double.parseDouble(scanner.nextLine());
- double discount = (meters * 7.61) * 0.18;
- double price = (meters * 7.61) - discount;
- System.out.println("The final price is: " + price);
- System.out.println("The discount is: " + discount);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment