题解列表

筛选

2805: 乘方计算

摘要:``` #include using namespace std; int main(){ int a,n,sum; cin>>a>>n; sum=1; for(int i=0;……

计算邮资 简洁写法

摘要:``` #include using namespace std; int main() { int n; char c; cin >> n >> c; int ans = 8;……

2892: 最好的草

摘要:对找到的草进行扩展参考代码:#include<iostream> #include<cstdio> #include<cstdlib> using namespace std; int m……

宏定义之闰年判断(常规解)

摘要:解题思路:闰年,就是能够被4整除且不能被100整除的年份(普通闰年),或者是能被400整除的年份(世纪闰年)注意事项:宏定义,是一个预处理命令,用来定义常量和函数,有以下三种。#define 标识符 ……