Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
41880 202103wsl 幸运数字 C++ 解答错误 0 1 MS 252 KB 287 2022-06-19 09:02:15

Tests(0/5):


#include<bits/stdc++.h> using namespace std; int check(int n){ if(n%4==0||n%7==0) return 1; while(n){ if(n%100==44||n%100==77) return 1; n/=10; } } int main(){ int n,s=0; cin>>n; for(int i=1;i<=n;i++){ int t; t=i; s+=check(t); } cout<<s; return 0; }


测评信息: