摘要: #include #include #include using namespace std; void solve(char *str) { vector v; char tmp[100]; int tmpcount = 0; for(int i=0; str[i]!='\0'; i++) { if(str[i]==' ' || st... 阅读全文
posted @ 2016-12-29 22:46 Hardsoftware 阅读(155) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; int compareStr(string str1, string str2) { int num1 = str1.length(); int num2 = str2.length(); if(num1>num2) return 1; if(num1str2[i]) ... 阅读全文
posted @ 2016-12-29 21:42 Hardsoftware 阅读(233) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; struct Data { int index; int value; }; struct myComp { bool operator()(const Data &a, const Data &b) { return a.index dataset; i... 阅读全文
posted @ 2016-12-29 16:30 Hardsoftware 阅读(192) 评论(0) 推荐(0) 编辑
摘要: #include #include using namespace std; int main() { int N; cin>>N; list li; int head; cin>>head; li.push_back(head); for(int i=0; i>a>>b; list::iterator itr; ... 阅读全文
posted @ 2016-12-29 13:37 Hardsoftware 阅读(147) 评论(0) 推荐(0) 编辑