题目链接:Codefoces 387A George and Sleep
题目大意:给出一个时间,然后往前推一个时间长度,给出那时的时间。
解题思路:水题,注意借位即可。
#include <stdio.h>
#include <string.h>
int main() {
int h, m, hh, mm;
scanf("%d:%d", &h, &m);
scanf("%d:%d", &hh, &mm);
int x, y;
if (mm > m) {
h--, m += 60;
}
y = m - mm;
x = (h + 24 - hh) % 24;
printf("%02d:%02d\n", x, y);
return 0;
}
分享到:
相关推荐
作者: George Polya / Gabor Szegö 副标题: Series, Integral Calculus, Theory of Functions (Classics in Mathematics) ISBN: 9783540636403 页数: 389 定价: USD 49.95 出版社: Springer 装帧: Paperback 出版...
Wriiten by George Pennachi, a very famous and classic material for asset pricing study. Theory of Asset Pricing unifies the central tenets and techniques of asset valuation into a single, ...
linear programming introduction.1997 George B. Dantzig and Mukund N. Thapa
"1984" is a long political novel written by the British left-wing writer George Orwell. It was first published in 1949 and is one of the representative works of dystopia.The work portrays the survival...
As in earlier Addison-Wesley books on the UNIX-based BSD operating system, Kirk McKusick and George Neville-Neil deliver here the most comprehensive, up-to-date, and authoritative technical ...
Design of Experiments for Engineers and Scientists Second Edition Design of Experiments (DOE) ...and Burman, Professor George Box, Professor Douglas Montgomery, Dr Genichi Taguchi and Dr Dorian Shainin.
Mastering AutoCAD 2018 and AutoCAD LT 2018 by George Omura English | 10 Apr. 2017 | ASIN: B06Y6JZ8M4 | 1080 Pages | AZW3 | 60.76 MB 30th Anniversary of the bestselling AutoCAD reference - fully ...
开源项目-George3d6-Hermes.zip,Hermes - a self contained, minimalist file-server written in go
as a self-study guide to AutoCAD and AutoCAD LT mastery, this book is the gold-standard, having led over a half million people on the journey to better design. If you’re ready to learn quickly so ...
During a thirteen-year hiatus from academic work before joining George Mason, he was director of research and design at the world's largest independent producer of Fortran and C general-purpose ...
George J Borjas - Labor Economics
masterpiece of mathematician
grow and advance for almost half a century. The history of expedition can be divided into three major periods: the early era, the middle age and the recent years. The official definition of robot by ...
Creating a Log-in Webpage The George Washington University Computer Science 1023 Professor Brenner
and Professor George J. Klir (The State University of New York at Binghamton) have published two books, Fuzzy Measure Theory (Plenum Press, New York, 1992) and Generalized Measure Theory (Springer-...
作者: G. Polya 副标题: Volume II Patterns of Plausible Inference ISBN: 9780691025100 定价: USD 29.95 出版社: Princeton University Press 装帧: Paperback 出版年: 1990-08-03
[算法技术手册].George.T.Heineman.扫描版
Booz,Alice Marcy, Bob Dunst, Mary Ann Fink, George Donzella, Kathie Gorski, Lou Hosta, Claire Wheeler John Graziadei, Joseph Stencel, Phil Franciskovich, Tom Myers, Holly Hogrefe, Carl Baker, John ...
很好的一本书 对学习数理逻辑的同学很有帮助