#include<bits/stdc++.h> using namespace std; const int f[10]={13,1,2,3,5,4,4,2,2,2}; int main(){ int p=0,q=0; for(int i=20000101;i<=20240413;++i){ int a=0,j=i; while(j){ a+=f[j%10]; j/=10; } if(a<=50)p++; else q++; } cout<<q<<'\n'; }
答案 396863968639686 wa了