2016年10月22日
摘要: 1 #include 2 using namespace std; 3 int main() 4 { 5 int i,j; 6 cin>>i>>j; 7 int max=0; 8 for(int t=i;tmax) max=len; 22 } 23 cout<<max<<endl; 24 return 0; 25 } 阅读全文
posted @ 2016-10-22 13:46 任我主宰 阅读(247) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std;int main(){ int n; while(cin>>n&&n!=0&&n<=4){ int t; int max=0; for(int i=0;i<n;i++){ cin>>t; if(t>max) max=t; } 阅读全文
posted @ 2016-10-22 13:45 任我主宰 阅读(161) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std;int main(){ struct student{ string studentname; int qimograde; int banjigrade; char xuesgb; char xibxs; int lunw 阅读全文
posted @ 2016-10-22 13:44 任我主宰 阅读(139) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std;int main(){ int ts; cin>>ts; for(int i=0;i<ts-1;i++){ int n,a,b; while(cin>>n){ int sum = 0; while(n--){ int t; 阅读全文
posted @ 2016-10-22 13:43 任我主宰 阅读(148) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std;int root(int s){ if(s<10){ return s; } else{ int a=s; int b=0; while(a!=0){ b+=a%10; a=a/10; } root(b); }}int ma 阅读全文
posted @ 2016-10-22 13:42 任我主宰 阅读(88) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>using namespace std;int main(){ int n; while(cin>>n&&n!=0){ int t; int t0=0; int sum=0; while(n--){ cin>>t; if(t>t0) sum += (t-t0)*6 阅读全文
posted @ 2016-10-22 13:41 任我主宰 阅读(107) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>#include<iomanip>#include<set>#include<vector>#include<algorithm>using namespace std;class SetOperation { public: // Add any codes y 阅读全文
posted @ 2016-10-22 13:40 任我主宰 阅读(154) 评论(0) 推荐(0) 编辑
摘要: #include<iostream>#include<string>#include<cstring>using namespace std;class String { public: String(); // str = "" String(const char*); // str = "abc 阅读全文
posted @ 2016-10-22 13:38 任我主宰 阅读(177) 评论(0) 推荐(0) 编辑
摘要: #include <iostream>#include <vector>#include <algorithm>using namespace std; class Student{ public: Student(string _name, int _score) { name = _name; 阅读全文
posted @ 2016-10-22 13:37 任我主宰 阅读(155) 评论(0) 推荐(0) 编辑
摘要: #include "Board.h" Board::Board(){ size = 10; s = new char[9]; set(); //对于棋盘的初始化 } char Board::getS(int i){ return s[i];} int Board::getSize(){ return 阅读全文
posted @ 2016-10-22 13:35 任我主宰 阅读(544) 评论(0) 推荐(0) 编辑