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 Volleyball
- {
- class Program
- {
- static void Main(string[] args)
- {
- var year = Console.ReadLine().ToString();
- var p = double.Parse(Console.ReadLine());
- // Number of holidays which are not weekend days
- var h = double.Parse(Console.ReadLine());
- // Numbers of holidays in which VLadi travels to Kaspichan
- var playedDays = 0.00;
- var weekendsInSofia = 48 - h;
- var weekendsInKaspichan = h;
- if ( year == "leap")
- {
- playedDays = ((weekendsInSofia * 0.75) + h + (p * 2/3));
- var leapYear = Math.Floor(1.15 * playedDays) + playedDays;
- Console.WriteLine("{0}", leapYear);
- }
- else if (year == "normal")
- {
- playedDays = Math.Floor((weekendsInSofia * 0.75) + h + (p * 2 / 3));
- Console.WriteLine("{0}", playedDays);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement