First, talk about constI have summarized them in three aspects: 1. Const constant; 2. Const pointer; 3. Application of const in function declaration.1, const constantIts definition form isConst type_name val_name;Note the initialization problem.
Recently, I started to write graphical programs.
Although there are also many shortcomings, how powerful Windows is as an operating system! Of course, this also makes writing programs very troublesome, especially when it comes to unicode encoding.
Today, I encountered a strange problem.
Development Environment:
1. Eclipse CDT, using the gcc compiler and function library of MinGW
2. Visual Studio 2008
Problem description:
A dll is compiled using gcc in eclipse cdt. This dll contains a
In the previous chapter of the injection code, we used VirtualAllocEx to open up a piece of memory for the other process, and copied the code into the memory of the other process to execute the code of that memory, however, there is a problem here,
I have never had a deep understanding of C ++. It seems that many cool people have read this Inside The C ++ Object Model. It seems that C ++ has to read this book in depth, so I decided to give it a try. After reading the directory on the day, you
1. What is a virtual function?
Simply put: ThoseVirtualThe member function modified by the keyword is a virtual function. Its main role is to achieve polymorphism.
Polymorphism is the core of object orientation. Its main idea is that it can adopt
1 Gprof
Practice
1. Time consumed for initializing large objects
The entire execution process is called 307 times, and the initialization time of the object accounts for 6.5%.Before the program enters the constructor, the parent class Object
Reading "C ++ meditation": copying Constructors
num= VehicleSurrogate parking_lot[ parking_lot[num++]=
The above section is explained in the book:
"This statement creates a copy of object x, binds the VehicleProxy object to this copy, and
Problem Description
Alice and Bob always love to play games, so does this time.It is their favorite stone-taken game.However, this time they does not compete but co-operate to finish this task.Suppose there is a stack of n stones.Each turn,Alice can
1. wstring string Conversion1) in win32, wchar_t occupies 2 bytes, and in linux, wchar_t occupies 4 bytes. The high bytes of wchar_t should be stored in the low bytes of the char array.2) win has the functions WideCharToMultiByte () and
The complexity related to C/C ++ programming, especially the maintenance of larger projects. If there are a large number of people and standards, it is a great burden. Recently, we are paying attention to the language such as go,
Prepare to
Function: enter a string to determine whether it is a return.
Mainly exercise pointer usage.
1. C Edition
# Include he [I =, flag = (a = getchar ())! ==++ N = (I =; I
The getchar () function obtains an input in sequence, assigns it to the char
(1) To use priority_queue, you must include the header file :# include (2) the priority_queue in the header file is defined as follows: namespace std {template , class Compare = less class priority_queue;} The first template parameter represents
2. Basic Windows Socket API Programming
Add the following statement to the program: # include # pragma comment (lib, "WS2_32 ")
When using Vc ++ for compilation, you need to add the compilation link dependency ws2_32.lib library.
Protocol
A vector is a container, a dataset, and contains many elements. The biggest difference from arrays is that vector can grow dynamically.
The key to implementing the big number operation using vector is to read a large number in string mode, then,
A derived class cannot directly access private members of a base class. to access a base class, you must use the base class interface, that is, its member functions. There are two implementation methods:
1. Add protection members to the declaration
You can use GetTcpTable to obtain the IP address, port, remote IP address, and port of the current process. However, you cannot associate the socket with the process name! You can use AllocateAndGetTcpExTableFromStack to implement this function, but
Now, I want to post an English post. I really don't want to translate it, and I don't feel like it is in place:
The STL is awash in comparisons of objects to see if they have the same value. for example, when you ask find to locate the first object
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service