vector<int> countBits(int num) { vector<int> res; res.push_back(0); if(num==0)return res; res.push_back(1); for(int i=2;i<=num;i++) { int a=res[i/2]+res[i%2]; res.push_back(a); } return res; }
posted on 2016-03-29 14:50 RenewDo 阅读(105) 评论(0) 编辑 收藏 举报