diff --git a/第一讲 变量、输入输出、表达式与顺序语句/654.cpp b/第一讲 变量、输入输出、表达式与顺序语句/654.cpp new file mode 100644 index 0000000..99b4ba2 --- /dev/null +++ b/第一讲 变量、输入输出、表达式与顺序语句/654.cpp @@ -0,0 +1,14 @@ +#include + +int main() +{ + int N; + int h, m, s; + scanf("%d", &N); + h = N / (60 * 60); + m = N % (60 * 60) / 60; + // s = N - h * (60 * 60) - m * 60; + s = N % 60; + printf("%d:%d:%d", h, m, s); + return 0; +}