ReferenceHttps://www.cnblogs.com/lidabo/p/5888997.htmlThe task has an update and cannot use the code of the article.Multiple filesTerminalTouch MAIN.C hw.c hw.hVscode hw.cVscodeOpen FolderPreparation of three project files1 /* hw.c */ 2 " hw.h " 3 4
Changing the signal screen word of a process can block the selected signal or unblock them. Use this technique to protect code critical sections that you do not want to be interrupted by a signal. What if you want to unblock a signal and then pause
One, Remove () functionRemove (beg,end,const t& value) //Remove interval {beg,end) for each element "equal to value";Remove is only removed by moving the iterator pointer forward, placing the element that is not deleted in front of the list, and
g++ compiles the C + + file and then takes the. in file in the same folder as the input for the run.The implementation of the Shell program refers to the Chen Feng of the teacher's batch file#!/bin/bashecho "编译"g++ "$1".cpp -lm -O2 -pipe -o "$1"echo
Condition 1 && Condition 2, if condition 1 is false, the condition 2 statement does not execute, because it can be judged that the expression is falseCondition 1 | | Condition 2, if condition 1 is true, the condition 2 statement does not execute
The basic way to work with circular statements:
Determine whether a loop body is executed by a conditional expression
Conditional expressions Follow the principle of an if statement expression
The difference between do,while,for:
C language programming requires attention to the difference between 64-bit and 32-machine, data types, especially int-related types, are different lengths under different bits of the machine's platform. The C99 standard does not specify the length
Course ObjectivesMaster in C + + development with millions processing capabilities of the service side, client communication technology. Share and pits the actual experience of the enterprise. Use C++TCP for network communication under the
Statement: Source code and "STL Source Analysis" (Houtie)Stl:C + + Standard Template Library, high versatility.Common data structures are encapsulated.Provides common general-purpose algorithms.STL six major components:Container algorithm iterator
In reality, the Library of C + + has a wide variety of problems, and the solution is extremely extensive, from lightweight to heavyweight. This article introduces you to 11 kinds of libraries, which are common to us, and are uncommon to see together.
Conditions (look at each of the basic types for a few bytes first):voidSize_ () {printf ("char type:%d\n",sizeof(Char)); printf ("int type:%d\n",sizeof(int)); printf ("Float type:%d\n",sizeof(float)); printf ("Double type:%d\n",sizeof(Double));
To address the problem of C + + memory leaks, C++11 introduced smart pointers (smart Pointer).The principle of smart pointers is to accept a well-applied memory address, construct a smart pointer object stored on the stack, there is an important
1. C + + Standard exception#include // std::exception2. Stack informationGets the stack information, mainly using execinfo.h several functions defined in.After throwing an exception, it is execinfo.h helpful to locate the problem by getting stack
Standard conversionsThe C + + language defines conversions between its underlying types. It also defines pointers, references, and conversions to pointer-derived types of members. These conversions are called "standard conversions."1. Integral type
ObjectiveThe recent period of time to look at the code, the use of C + + smart pointers, found that they can not understand the code in the expression of what meaning, so dedicated to take a time to make up their own this lack of knowledge.Reference
When you recently worked on a project (platform. NET 4.0 WinForm), the customer asked the software to provide boot-start Setup optionsAt the beginning, the implementation method is as follows: Public classBoot {//writing to the registry
String.Join methodThe String.Join () method is often used in common work, and there are nine (overloaded) methods in the runtime (System.Runtime, version=4.2.0.0) used with vs 2017.// //Summary://concatenates the members of a collection,
? One of the reasons for generics is to solve the boxing and unpacking problems of elements in the original collection class:First, the generic type: /// ///return to foreground message/// /// Public classYzt_message {
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