Advertisement
Vankata17

BORSA

Oct 8th, 2019
167
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.67 KB | None | 0 0
  1. import java.util.Scanner;
  2. public class IVAN {
  3.  
  4.     public static void main(String[] args) {
  5.  
  6.  
  7.        
  8.         Scanner scan = new Scanner(System.in);
  9.         System.out.print("VEGETABLE lv:  ");
  10.         double veg1 = scan.nextDouble();
  11.         System.out.print("FRUIT lv:  ");
  12.         double fru1 = scan.nextDouble();
  13.         System.out.print("VEGETABLE KG:  ");
  14.         double veg2 = scan.nextDouble();
  15.         System.out.print("FRUIT KG:  ");
  16.         double fru2 = scan.nextDouble();
  17.         double result1 = veg1*veg2;
  18.         System.out.println("PRICE:  "+ result1);
  19.         double result2 = fru1*fru2;
  20.         System.out.print("PRICE  "+ result2);
  21.         //double result3 = (result1 + result2)/1.94;
  22.         //System.out.print("EURO  "+ result3);
  23.     }
  24.  
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement