Advertisement
miglenabs

Untitled

Nov 2nd, 2021
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.88 KB | None | 0 0
  1. using System;
  2.  
  3. namespace Supplies_for_School
  4. {
  5. class Program
  6. {
  7. static void Main(string[] args)
  8. {
  9. int pensQuantity = int.Parse(Console.ReadLine());
  10. int markersQuantity = int.Parse(Console.ReadLine());
  11. int preparQuantity = int.Parse(Console.ReadLine());
  12. int percentDiscount = int.Parse(Console.ReadLine());
  13.  
  14.  
  15.  
  16. double pensPrice = pensQuantity * 5.80;
  17. double markersPrice = markersQuantity * 7.20;
  18. double preparPrice = preparQuantity * 1.20;
  19. double materialsPrice = pensPrice + markersPrice + preparPrice;
  20. double discount= percentDiscount / 100;
  21.  
  22. double discountSum= materialsPrice-discount;
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33. Console.WriteLine(discountSum);
  34.  
  35.  
  36. }
  37. }
  38. }
  39.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement