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 ConsoleApplication9
- {
- class Program
- {
- static void Main(string[] args)
- {
- int hour= int.Parse(Console.ReadLine());
- int min= int.Parse(Console.ReadLine());
- min = min + 15;
- if( min >= 60)
- {
- min -= 60;
- hour++;
- }
- if( hour >=24)
- {
- hour -= 24;
- }
- //if( hour > 23 && min > 59)
- // {
- // hour = 0;
- // }
- if(min < 10)
- {
- Console.WriteLine("{0}:0{1}",hour,min);
- }
- else
- {
- Console.WriteLine("{0}:{1}",hour,min);
- }
- }
- }
- }
Add Comment
Please, Sign In to add comment