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 TrainingLab
- {
- class Program
- {
- static void Main(string[] args)
- {
- var n = double.Parse(Console.ReadLine());
- var time = Console.ReadLine();
- if (n < 20 && n > 0 && time == "day")
- {
- Console.WriteLine(0.70 + (n * 0.79));
- }
- else if (n < 20 && n > 0 && time == "night")
- {
- Console.WriteLine(0.70 + (n * 0.90));
- }
- else if (n >= 100 && n < 5001 && time == "day")
- {
- Console.WriteLine(n * 0.06);
- }
- else if (n >= 100 && n < 5001 && time == "night")
- {
- Console.WriteLine(n * 0.06);
- }
- else if (n >= 20 && n < 100 && time == "day")
- {
- Console.WriteLine(n * 0.09);
- }
- else if (n >= 20 && n < 100 && time == "night")
- {
- Console.WriteLine(n * 0.09);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement