1049 Counting Ones (30 point(s))

題解 數位dp。 #include<iostream> #include<cstdio> #include<cstring> #include<cmath> using namespace std; typedef long long ll; ll dp[20]; // 前x位中1出現次數(0~9均是如此) void init() { memset(dp, 0, sizeof(dp))
相關文章
相關標籤/搜索