Advertisement
Monteso

Untitled

Oct 6th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.63 KB | None | 0 0
  1. using System;
  2.  
  3. namespace Tailoring_Workshop
  4. {
  5.     class Program
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.             var numberTables = double.Parse(Console.ReadLine());
  10.             var p = double.Parse(Console.ReadLine());
  11.             var w = double.Parse(Console.ReadLine());
  12.  
  13.             var pokrivki = numberTables * (p + 2 * 0.30) * (w + 2 * 0.30);
  14.             var kareta = numberTables * (p / 2) * (p / 2);
  15.             var price = pokrivki * 7 + kareta * 9;
  16.  
  17.             Console.WriteLine("{0:f2}", price + " USD");
  18.             Console.WriteLine("{0:f2}", price * 1.85 + " BGN");
  19.         }
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement