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 _12_Volleyball
- {
- class Program
- {
- static void Main(string[] args)
- {
- var god = Console.ReadLine().ToLower();
- var p = double.Parse(Console.ReadLine());
- var h = double.Parse(Console.ReadLine());
- var weekend = 48;
- if (god == "leap")
- {
- double sofiaw = weekend - h;
- sofiaw = sofiaw * 3.0 / 4;
- double sofiap = p * 2.0 / 3;
- double sofiashumen = sofiaw + h + sofiap;
- double procent = sofiashumen * 0.15;
- double total = sofiashumen + procent;
- Console.WriteLine(Math.Truncate(total));
- }
- if (god == "normal")
- {
- double sofiaw = weekend - h;
- sofiaw = sofiaw * 3.0 / 4;
- double sofiap = p * 2.0 / 3;
- double sofiashumen = sofiaw + h + sofiap;
- Console.WriteLine(Math.Truncate(sofiashumen));
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement