摘要:
list& DeleteRepeatElements (list&lst){ lst.sort(); lst.unique(); for (conststring &each_word : lst)cout << each_word << " "; cout<< endl; returnlst... 阅读全文
摘要:
int main (int argc, char* argv[]){std::ios::sync_with_stdio (false); //忽略列表 setexclude ={ "fuck", "damn" }; stringword; map word_count; while (cin>... 阅读全文
摘要:
int main (int argc, char* argv[]){std::ios::sync_with_stdio (false); stringfirstName, lastName; multimap>kidsNames; while (cin>> firstName >> lastN... 阅读全文
摘要:
int main (int argc, char* argv[]){std::ios::sync_with_stdio (false);//将范围从v.begin()到v.end()的元素copy到c的end()处 copy(v.begin (), v.end (), inserter (c, c.... 阅读全文
摘要:
int main (){ cout<< "Please input some numbers:" << endl;//定义输入流迭代器和尾后迭代器istream_iterator input_number_it (cin),eof;//用迭代器与尾后迭代器初始化vectorvectornumb... 阅读全文
摘要:
#include#define ARR_SIZE(a)(sizeof((a)) / sizeof((a[0])))int a[] = {1, 23, 32, 0, 2, 5, 23};void insert_sort(int *a, int n) { int i, j,temp; for (i... 阅读全文
摘要:
引用地址: http://blog.csdn.net/caroline_wendy题目: 写一个函数,求两个整数之和, 要求在函数体内不得使用+, -, *, /四则运算符号.不能使用运算符号,使用位运算,第一步异或运算选位,第二步与运算进位.代码:[cpp] view plaincopy#incl... 阅读全文
摘要:
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;namespace Csharp{ classProgram {static ... 阅读全文
摘要:
int main (int argc, char* argv[]){vectornumbers; cout numbers.begin ();)cout << *--it << " "; cout<< endl; return0;} 阅读全文
摘要:
int main (int argc, char* argv[]){std::ios::sync_with_stdio (false); ifstreamfile; file.open(argv[1]); mapword_count; string word,line; while(getline ... 阅读全文