Advertisement
koksibg

FishMarket

Nov 20th, 2016
261
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.86 KB | None | 0 0
  1. using System;
  2.  
  3. namespace FishMarket
  4. {
  5.     class FishMarket
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.             double mackerel = double.Parse(Console.ReadLine()); // скумрия лв/кг
  10.             double sprat = double.Parse(Console.ReadLine()); // цаца лв/кг
  11.             double beltedbonito = double.Parse(Console.ReadLine()); // паламуд -кг
  12.             double scad = double.Parse(Console.ReadLine()); // сафрид- кг
  13.             int clams = int.Parse(Console.ReadLine()); // миди  -кг
  14.             double priceBeltedbonito = mackerel + mackerel * 0.6;
  15.             double priceScad = sprat + sprat *0.8;
  16.             double priceClams = 7.50;
  17.             double many = priceBeltedbonito * beltedbonito + priceScad * scad + (double)priceClams * clams;
  18.             Console.WriteLine($"{many:f2}");
  19.         }
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement