Advertisement
Spocoman

01. Sino The Walker

Feb 9th, 2024 (edited)
914
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.68 KB | None | 0 0
  1. using System;
  2. using System.Linq;
  3. using System.Numerics;
  4. using System.Collections;
  5. using System.Collections.Generic;
  6.  
  7. namespace SinoTheWalker
  8. {
  9.     class Program
  10.     {
  11.         static void Main(string[] args)
  12.         {
  13.             var timee = Console.ReadLine().Split(':').Select(int.Parse).ToList();
  14.  
  15.             int steps = int.Parse(Console.ReadLine());
  16.             int stepPerSeconds = int.Parse(Console.ReadLine());
  17.  
  18.             BigInteger totalSeconds =  timee[0] * 3600 + timee[1] * 60 + timee[2] + steps * stepPerSeconds;
  19.  
  20.             Console.WriteLine($"Time Arrival: {totalSeconds / 3600 % 24:D2}:{totalSeconds % 3600 / 60:D2}:{totalSeconds % 60:D2}");
  21.         }
  22.     }
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement