Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace _05
- {
- class Program
- {
- static void Main(string[] args)
- {
- //разходи: наем, напитки, кетъринг, подаръци
- int rent = int.Parse(Console.ReadLine()); //наем за залата
- int catering = rent * 2; //цена за кетъринга
- double drinks = catering - 0.15 * catering; //цена за напитки
- double gifts = (catering + drinks) / 7; //цена за подаръци
- //обща сума за разходи = наем за залата + цена за кетъринга + цена за напитки + цена за подаръци
- double totalSum = rent + catering + drinks + gifts;
- //отпечатваме обща сума за разходи
- Console.WriteLine($"{totalSum:F2}");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement