Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
100377 | 吴梓玄 | 12满足条件的四位数 | C | Accepted | 1 MS | 200 KB | 258 | 2024-12-07 16:48:02 |
#include <stdio.h> int main() { int a,s=0; scanf("%d",&a); for(int i=1;i<=a;++i){ int t,w,x,y,z; scanf("%d",&t); w=t/1000; x=(t/100)%10; y=(t/10)%10; z=t%10; if (z-w-x-y>0){ s=s+1; } } printf("%d",s); return 0; }