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 Company
- {
- class company
- {
- static void Main(string[] args)
- {
- var neededHours = int.Parse(Console.ReadLine());
- var days = int.Parse(Console.ReadLine());
- var employees = int.Parse(Console.ReadLine());
- var hoursReal = (days - 0.1 * days)*8; //realno vreme v 4asove za rabota
- var dopulnitelniHours = employees * 2 * days;
- var hoursRealTotal = hoursReal + dopulnitelniHours;
- if (hoursRealTotal>= neededHours)
- {
- Console.WriteLine("Yes!{0} hours left.", Math.Floor(hoursRealTotal - neededHours));
- }
- else if (hoursRealTotal<neededHours)
- {
- Console.WriteLine("Not enough time!{0} hours needed.", Math.Floor(neededHours-hoursRealTotal));
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment