当前位置:网站首页>Write a 2-minute countdown.
Write a 2-minute countdown.
2022-07-03 14:37:00 【Ah Jiong of spade K】
#include <stdio.h>
#include <stdlib.h>
#include<windows.h>
int main()
{ int a;
a=120;
while(a>=0)
{
system("cls");
printf("%d:%d",a/60,a%60);
a=a-1;
Sleep(1000);
}
return 0;
}
Experience : The idea of solving problems is very important , Minutes is equivalent to 60 Base number , The first half is the integer part of the division , The second half is remainder , It can be extended to other decimal countdown .
边栏推荐
- 洛谷P4047 [JSOI2010]部落划分 题解
- retrofit
- Sub-GHz无线解决方案Z-Wave 800 系列ZG23 soc和ZGM230S模块
- tonybot 人形机器人 首次开机 0630
- FPGA blocking assignment and non blocking assignment
- Bibit pharmaceutical rushed to the scientific innovation board: annual revenue of 970000, loss of 137million, proposed to raise 2billion
- 洛谷P5194 [USACO05DEC]Scales S 题解
- Luogu p4047 [jsoi2010] tribal division solution
- Why is this error reported when modifying records in the database
- NFT new opportunity, multimedia NFT aggregation platform okaleido will be launched soon
猜你喜欢
Frequently asked questions: PHP LDAP_ add(): Add: Undefined attribute type in
洛谷P5018 [NOIP2018 普及组] 对称二叉树 题解
retrofit
To improve efficiency or increase costs, how should developers understand pair programming?
X86 assembly language - Notes from real mode to protected mode
puzzle(016.4)多米诺效应
分布式事务(Seata) 四大模式详解
Code writing and playing method of tonybot humanoid robot at fixed distance
分布式事务(Seata) 四大模式详解
天谋科技 Timecho 完成近亿元人民币天使轮融资,打造工业物联网原生时序数据库
随机推荐
retrofit
Zzuli:1047 logarithmic table
Detailed explanation of four modes of distributed transaction (Seata)
适用于XP的DDK
7-9 one way in, two ways out (25 points)
Facebook 如何将 Instagram 从 AWS 搬到自己的服务器
Time conversion ()
Find specified characters
Tonybot humanoid robot checks the port and corresponds to port 0701
Zzuli:1040 sum of sequence 1
String sort
puzzle(016.3)千丝万缕
Output student grades
Niuke: crossing the river
Zhonggan micro sprint technology innovation board: annual revenue of 240million, net loss of 17.82 million, proposed to raise 600million
Puzzle (016.4) domino effect
1017 a divided by B (20 points)
[qingniaochangping campus of Peking University] in the Internet industry, which positions are more popular as they get older?
Use of form text box (I) select text
MySQL multi table query subquery