摘要: 直接从后面往前面扫,如果前面大,就把后面丢掉再把前面剩下的进行类似的处理就行;#include#include#include#define maxn 100005using namespace std;char s[maxn];int main(){ cin>>s; int l=strlen(s); int head=l-1,tail=l-1; int cnt=1; while(1) { while(s[head]=='0')head--; if(head>(tail-head+1)) { c... 阅读全文
posted @ 2014-02-24 12:33 Yours1103 阅读(184) 评论(0) 推荐(0) 编辑