Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace SoftuniRecepcion
- {
- class Program
- {
- static void Main(string[] args)
- {
- int employee1 = int.Parse(Console.ReadLine());
- int employee2 = int.Parse(Console.ReadLine());
- int employee3 = int.Parse(Console.ReadLine());
- int students = int.Parse(Console.ReadLine());
- int studentsPerHour = employee1 + employee2 + employee3;
- if (studentsPerHour != 0)
- {
- double time = Math.Ceiling(students / (studentsPerHour * 1.00));
- if (time > 3)
- {
- time = 4 * time / 3;
- }
- Console.WriteLine($"Time needed: {(int)time}h.");
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement