摘要: 在区间内统计任意两位相差大于二的数的个数。数位dp在推到时候注意最高位要特判一下因为最高位是没有前一位的。 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 #define ll long long 8 #define LEN 100 9 10 using namespace std;11 12 ll dp[LEN][LEN];13 14 inline int abs(int x){return x>0?x:-x;}15 16 void init()17 {18 memset(dp, 0,... 阅读全文
posted @ 2013-12-02 09:15 张小豪 阅读(194) 评论(0) 推荐(0) 编辑