1 条题解
-
0
C :
#include<stdio.h> main(){ int a,b,c,d,e,sum=0; for (a=1;a<=9;a++) for(b=0;b<=9;b++) for(c=0;c<=9;c++) for(d=0;d<=9;d++) for(e=0;e<=9;e++){ if(a!=4&&b!=4&&c!=4&&e!=4&&d!=4) sum+=1;} printf("%d",sum); return 0; }C++ :
#include<cstdio> using namespace std; int main() { int a,b,c,d,e,sum=0; //freopen("1.in","r",stdin); //freopen("1.out","w",stdout); for(a=1;a<=9;a++) for(b=0;b<=9;b++) for(c=0;c<=9;c++) for(d=0;d<=9;d++) for(e=0;e<=9;e++) if(a!=4 && b!=4 && c!=4 && d!=4 && e!=4) sum++; printf("%d\n",sum); return 0; }
- 1
信息
- ID
- 3295
- 时间
- 1000ms
- 内存
- 256MiB
- 难度
- (无)
- 标签
- (无)
- 递交数
- 0
- 已通过
- 0
- 上传者