Advertisement
Guest User

Untitled

a guest
Jul 1st, 2016
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6.  
  7. namespace Sum_Seconds
  8. {
  9. class Program
  10. {
  11. static void Main(string[] args)
  12. {
  13. var first = double.Parse(Console.ReadLine());
  14. var second = double.Parse(Console.ReadLine());
  15. var third = double.Parse(Console.ReadLine());
  16. var score = first + second + third;
  17. var minutes = score / 60;
  18. var seconds = score % 2;
  19. if(score <= 59)
  20. {
  21. minutes = 0;
  22. seconds = score;
  23. }
  24. else if(score > 60 && score < 119)
  25. {
  26. minutes = 1;
  27. seconds = score - 60;
  28. }
  29. else if(score > 120 && score < 179)
  30. {
  31. minutes = 2;
  32. seconds = score - 120;
  33. }
  34. else if ( seconds < 10)
  35. {
  36. { 0:00};
  37. }
  38. }
  39. }
  40. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement