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 PC_Store
- {
- class Program
- {
- static void Main(string[] args)
- {
- double processor = double.Parse(Console.ReadLine());
- double videocard = double.Parse(Console.ReadLine());
- double ram = double.Parse(Console.ReadLine());
- double ramCount = double.Parse(Console.ReadLine());
- double discount = double.Parse(Console.ReadLine());
- double processorPriceLv = processor * 1.57;
- double processorPriceAfterDiscount = processorPriceLv - (processorPriceLv * discount);
- double videocardPriceLv = videocard * 1.57;
- double videocardPriceAfterDiscount = videocardPriceLv - (videocardPriceLv * discount);
- double ramPriceLv = (ram * ramCount) * 1.57;
- double totalPrice = processorPriceAfterDiscount + videocardPriceAfterDiscount + ramPriceLv;
- Console.WriteLine("Money needed - {0:f2} leva.", totalPrice);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement