摘要: #include <iostream>#include <cmath>#include <vector>using namespace std;void main(){ double area=50; double R=0; int line; cin>>line; int i; double x,y; vector<double> dist; vector<double>::iterator dit; vector<int> res; vector<int>::iterator rit; for 阅读全文
posted @ 2012-02-09 17:23 Dsp Tian 阅读(436) 评论(0) 推荐(0) 编辑
摘要: #include <iostream>#include <vector>using namespace std;void main(){ int i; int month=12; double mean=0; double num; vector<double> vect; vector<double>::iterator vit; for (i=0;i<month;i++) { cin>>num; vect.push_back(num); } for (vit=vect.begin();vit!=vect... 阅读全文
posted @ 2012-02-09 15:25 Dsp Tian 阅读(481) 评论(0) 推荐(0) 编辑
摘要: #include <iostream>#include <string>using namespace std;void main(){ string card="card(s)"; double num=2; double res=0; double end; cin>>end; int what=0; while (res<=end) { res+=1/(num++); what++; } if (end>0) cout<<what<<" "<<card<< 阅读全文
posted @ 2012-02-09 15:10 Dsp Tian 阅读(395) 评论(0) 推荐(0) 编辑
摘要: #pragma warning (disable:4786)#include <iostream>#include <map>#include <algorithm>#include <string>#include <vector>using namespace std;typedef struct { string first; int second;}res;bool less_first(res tmp1,res tmp2){ return tmp1.first<tmp2.first;}bool my_equal(res 阅读全文
posted @ 2012-02-09 13:12 Dsp Tian 阅读(476) 评论(0) 推荐(0) 编辑
摘要: #include <string.h>#include <vector>#include <algorithm>#include <string>#include <iostream>using namespace std;void main(){ string m("----------asdfas--------------dfgdf---------"); string::iterator it; vector<char> csr; vector<char>::iterator cit 阅读全文
posted @ 2012-02-09 01:03 Dsp Tian 阅读(687) 评论(0) 推荐(0) 编辑