摘要: #include "stdio.h" #include "stdlib.h" #include "time.h" int main() { int i; char a, b; srand((unsigned)time(NULL)); a = 6; b = rand() % 6 + 1; for (i = 1; i = 7 && a <= 13) ... 阅读全文
posted @ 2019-03-24 21:29 王祉 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 闰年判断 (1)闰年定义:1.除100余数非0且除4余0 2.除400余数为0 (2)流程图: 代码1:(c语言) #include <stdio.h> int main(){ int year = 2000; while (year <= 2500) { if (year % 100 != 0 & 阅读全文
posted @ 2019-03-10 09:37 王祉 阅读(1075) 评论(0) 推荐(0) 编辑