bacco

Задача: Зеленчукова борса

Jan 20th, 2018
64
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.58 KB | None | 0 0
  1. using System;
  2.  
  3. namespace DDDDDDDDDDDDDDDDDDDDDD
  4. {
  5.     class Program
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.  
  10.            
  11.             double priceVeg = double.Parse(Console.ReadLine());
  12.             double priceFrut = double.Parse(Console.ReadLine());
  13.             int kgVeg = int.Parse(Console.ReadLine());
  14.             int kgFrut = int.Parse(Console.ReadLine());
  15.  
  16.             double euro = 1.94;
  17.  
  18.             double profit = ((priceVeg * kgVeg) + (priceFrut * kgFrut)) / euro;
  19.  
  20.             Console.WriteLine(Math.Round(profit,2));
  21.  
  22.  
  23.  
  24.         }
  25.     }
  26. }
Add Comment
Please, Sign In to add comment