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 Exer_CharityCompany
- {
- class Program
- {
- static void Main(string[] args)
- {
- int days = int.Parse(Console.ReadLine());
- int bakers = int.Parse(Console.ReadLine());
- int cakes = int.Parse(Console.ReadLine());
- int wafles = int.Parse(Console.ReadLine());
- int pankes = int.Parse(Console.ReadLine());
- double totalcakesPrice = cakes * 45;
- double totalwaflesPrice = wafles * 5.80;
- double totalpankesPrice = pankes * 3.20;
- double totalSum = (totalcakesPrice + totalwaflesPrice + totalpankesPrice) * bakers;
- double finalMoney = totalSum * days;
- double totalMoney = finalMoney - (finalMoney / 8);
- Console.WriteLine("{0:F2}", totalMoney);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment