Advertisement
YavorJS

Thea the Photographer

Sep 25th, 2016
403
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. using System;
  2.  
  3. class Thea
  4. {
  5. static void Main(string[] args)
  6. {
  7. long numberOfPics = long.Parse(Console.ReadLine());
  8. long filterTimePic = long.Parse(Console.ReadLine());
  9. long filterFactor= long.Parse(Console.ReadLine());
  10. long uploadTimePic = long.Parse(Console.ReadLine());
  11. long filteredPics = (long)(Math.Ceiling(numberOfPics * filterFactor / 100d));
  12. long timeToFilterPics = numberOfPics * filterTimePic;
  13. long timeToUploadPics = filteredPics * uploadTimePic;
  14. long totalTime = timeToFilterPics + timeToUploadPics;
  15. TimeSpan time = TimeSpan.FromSeconds(totalTime);
  16. Console.WriteLine("{0:d\\:hh\\:mm\\:ss}", time);
  17. }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement