当前位置:网站首页>Chapter five
Chapter five
2020-11-08 20:18:00 【Half a spoon of coffee】
1.# ··· #include<stdio.h> #define MIn_PER_HOU 60 int main(int argc,char*argv[]){ int hours, minutes, input; printf("CONVERT MINUTES TO HOURS!\n"); printf("PLEASE INPUT THE NUMBER OF MINUTES:"); scanf("%d", &input); while (input > 0) { hours = input / MIn_PER_HOU; minutes = input % MIn_PER_HOU; printf("CONVERT TO %d HOUR AND %d MINUTES\n", hours, minutes); printf("PLEASE CONTINUE INPUT THE NUMBER OF MINUTES:"); scanf("%D", &input); } printf("PROGRAM EXIT!\n"); }
#include<stdio.h>
void main() { int a, b; printf(" Input number :"); scanf("%d", &a); b = a; while (b <= a + 10) { printf("%d\n", b); b++; }
}
#include<stdio.h>
void main() { int b; printf(" Enter the number of days :"); scanf("%d", &b); while (b >0) { printf("%d days are %d weeks, %d days.\n", b,b/7,b%7); printf(" Enter the number of days :"); scanf("%d", &b); }
}
#include<stdio.h>
void main() { float b; printf(" Enter the height :"); scanf("%f", &b); while (b > 0) { printf("%.0fcm =%.2f feet,%.2f inches\n", b, b / 30.48, b / 2.54); printf(" Enter the height :"); scanf("%d", &b); }
}
版权声明
本文为[Half a spoon of coffee]所创,转载请带上原文链接,感谢
边栏推荐
猜你喜欢

To introduce to you, this is my flow chart software—— draw.io

Newbe.ObjectVisitor 样例 1

动态规划之子序列问题解题模板

Exercise 5

C / C + + knowledge sharing: function pointer and pointer function, can you understand after reading this article?

经典动态规划:最长公共子序列

experiment

Dynamic relu: Microsoft's refreshing device may be the best relu improvement | ECCV 2020

【Elasticsearch 技术分享】—— 十张图带大家看懂 ES 原理 !明白为什么说:ES 是准实时的!

. net core cross platform resource monitoring library and dotnet tool
随机推荐
如何将PyTorch Lightning模型部署到生产中
微信小程序相关
CountDownLatch 瞬间炸裂!同基于 AQS,凭什么 CyclicBarrier 可以这么秀?
Select sort
getBytes之 LengthFieldBasedFrameDecoder服务端解析
Simple process of reading pictures by QT program developed by Python
采用注解+拦截器的方式进行异步执行的实现方式
【杂谈】JS相关的线程模型整理
Introduction to latex
Mongodb database
Solution to cross domain problem of front end separation
C/C++学习日记:原码、反码和补码
PAT_ Grade A_ 1056 Mice and Rice
学会了volatile,你变心了,我看到了
Deep copy
CountDownLatch 瞬间炸裂!同基于 AQS,凭什么 CyclicBarrier 可以这么秀?
Using fastai to develop and deploy image classifier application
Looking for a small immutable dictionary with better performance
Package subsystem in Simulink
An online accident caused by improper use of thread pool