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 ConsoleApplication2
- {
- class Program
- {
- static void Main(string[] args)
- {
- Console.WriteLine("enter sales per month");
- double sales = double.Parse(Console.ReadLine());
- double money = 0.0;
- if (sales < 20000)
- {
- for (int i = 1; i <= 12; i++)
- {
- money = money + (sales * 0.05);
- Console.WriteLine("sales for month {0} is {1} $", i, (money + sales));
- }
- Console.WriteLine("and the total money after a year is : " + (sales + money));
- }
- else if (sales >= 20000 && sales <= 40000)
- {
- for (int i = 1; i <= 12; i++)
- {
- money = money + (sales * 0.75);
- Console.WriteLine("sales for month {0} is {1} $", i, (money + sales));
- }
- Console.WriteLine("and the total money after a year is : " + (sales + money));
- }
- else if (sales > 40000)
- {
- for (int i = 1; i <= 12; i++)
- {
- money = money + (sales * 1.2);
- Console.WriteLine("sales for month {0} is {1} $", i, (money + sales));
- }
- Console.WriteLine("and the total money after a year is : " + (sales + money));
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement