Created
June 6, 2015 12:14
-
-
Save vdonchev/a4c130dcea0dcc463708 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
class Volleyball | |
{ | |
static void Main() | |
{ | |
string yearType = Console.ReadLine(); | |
int hollydays = int.Parse(Console.ReadLine()); | |
int homwtownWeekends = int.Parse(Console.ReadLine()); | |
int normalWeekends = 48 - homwtownWeekends; | |
double totalPlays = homwtownWeekends + (normalWeekends * 0.75D) + ((hollydays / 3D) * 2D); | |
totalPlays += (yearType == "leap") ? totalPlays * 0.15D : 0; | |
Console.WriteLine((int)totalPlays); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment