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 Firm
- {
- class Program
- {
- static void Main(string[] args)
- {
- int hoursNeeded = int.Parse(Console.ReadLine());
- int days = int.Parse(Console.ReadLine());
- int workers = int.Parse(Console.ReadLine());
- double workDays = days * 0.9;
- double workHours = workDays * workers * (8 + 2);
- workHours = Math.Floor(workHours);
- if (workHours >= hoursNeeded)
- {
- Console.WriteLine("Yes!{0} hours left.", workHours - hoursNeeded);
- }
- else
- {
- Console.WriteLine("Not enough time!{0} hours needed.", hoursNeeded - workHours);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement