当前位置:网站首页>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 .
边栏推荐
- Zzuli:1053 sine function
- dllexport和dllimport
- 7-17 crawling worms (break exercise)
- 【7.3】146. LRU缓存机制
- 7-23 currency conversion (using array conversion)
- Zzuli:1048 factorial table
- Four data flows and cases of grpc
- 修改数据库中的记录为什么报这个错
- Zzuli:1055 rabbit reproduction
- ZABBIX saves the page blank after adding calculated items
猜你喜欢

Understand the application scenario and implementation mechanism of differential segment

Bibit pharmaceutical rushed to the scientific innovation board: annual revenue of 970000, loss of 137million, proposed to raise 2billion

puzzle(016.4)多米诺效应

Bucket sorting in C language

Sub-GHz无线解决方案Z-Wave 800 系列ZG23 soc和ZGM230S模块

Tonybot Humanoïde Robot Infrared Remote play 0630

7-15 calculation of PI

MySQL multi table query subquery

基因家族特征分析 - 染色体定位分析

编程语言:类型系统的本质
随机推荐
String substitution
Recent learning summary
puzzle(016.3)千丝万缕
7-14 sum integer segments (C language)
Sendmail无法发送邮件及发送过慢解决
Plane vector addition
retrofit
Selective sorting
Sword finger offer 28 Symmetric binary tree
Doris学习笔记之数据表的创建
NPM install is stuck with various strange errors of node NPY
7-28 monkeys choose King (Joseph problem)
7-18 finding the single root of polynomial by dichotomy
数学常数表 by q779
Timecho of Tianmou technology completed an angel round financing of nearly 100 million yuan to create a native timing database of the industrial Internet of things
Jiuyi cloud black free encryption free version source code
Programming language: the essence of type system
Pyqt interface production (login + jump page)
Sendmail can't send mail and it's too slow to send. Solve it
Zzuli:1048 factorial table