摘要:
Deque和Vector类似,只不过deque头尾都开放,能够在头尾进行快速插入和删除操作DequeTest.cpp#include #include #include #include #include #include "DequeTest.h"using namespace std;void ... 阅读全文
摘要:
VectorTest.cpp#include #include #include #include #include #include "VectorTest.h"using namespace std;void VectorTest::simpleOperation(){ // create... 阅读全文
摘要:
Array是C++ 11给STL新增加的容器ArrayTest.cpp#include #include #include #include #include "../../Core/print.hpp"#include "ArrayTest.h"using namespace std;void A... 阅读全文
摘要:
服务端:hello_server.c#include #include #include #include #include #include void error_handling(char *message);int main(int argc, char *argv[]){ int se... 阅读全文
摘要:
A lambda expression is an unnamed block of code (or an unnamed function) with a list of formal parameters and abody.Java8中的lambda表达式不同于C#,使用的是->eg:// ... 阅读全文
摘要:
给程序加上控制台菜单menu.pyimport sysfrom notebook import Notebook, Noteclass Menu: '''Display a menu and respond to choices when run.''' def __init__(sel... 阅读全文
摘要:
notebook.pyimport datetimelast_id = 0class Note: '''Represent a note in the notebook. Match against a string in searches and store tags for each... 阅读全文
摘要:
每次循环把最小的值往前移C++代码:Sorter.hpp#ifndef _Algorithm_Sorter_H_#define _Algorithm_Sorter_H_template class Sorter{public: static void selectionSort(Item a[... 阅读全文
摘要:
UDP provides an end-to-end service different from that of TCP.In fact, UDP performs only two functions:(1) it adds another layer of addressing (ports)... 阅读全文
摘要:
1. 预定义函数对象C++标准库内含许多预定义的函数对象,也就是内置的函数对象。你可以充分利用他们,不必自己费心去写一些自己的函数对象。要使用他们,你只要包含如下头文件#include eg:set> coll; // sort elements with > coll; // sort eleme... 阅读全文