Problem 2592 --Time Zone

2592: Time Zone

"
Time Limit $1$ 秒/Second(s) Memory Limit $512$ 兆字节/Megabyte(s)
提交总数 $3$ 正确数量 $3$
裁判形式 标准裁判/Standard Judge 我的状态 尚未尝试
难度 分类标签
Chiaki often participates in international competitive programming contests. The time zone becomes a big problem.
Given a time in Beijing time (UTC +8), Chiaki would like to know the time in another time zone s.
There are multiple test cases. The first line of input contains an integer T (1≤T≤106), indicating the number of test cases. For each test case:
The first line contains two integers ab (0≤a≤23,0≤b≤59) and a string s in the format of "UTC+X'', "UTC-X'', "UTC+X.Y'', or "UTC-X.Y'' (0≤X,X.Y≤14,0≤Y≤9).
For each test, output the time in the format of hh:mm (24-hour clock).
3
11 11 UTC+8
11 12 UTC+9
11 23 UTC+0
11:11
12:12
03:23

推荐代码 查看2592 所有题解 上传题解视频得图灵币

本题记录 用 户(点击查看用户) 运行号(点击购买题解) 时 间
算法最快[$241 $ms] 刘欢@计算机科学与技术161 269282 2018-08-07 21:21:34
内存最少[$0 $KB] 淡意的温柔 606330 2020-07-09 15:31:46
第一AC 刘欢@计算机科学与技术161 269282 2018-08-07 21:21:34
第一挑战 刘欢@计算机科学与技术161 269282 2018-08-07 21:21:34

赛题来源/所属竞赛 HDU N/A

竞赛编号 竞赛名称 竞赛时间 访问比赛