This log is to start from a running example, once you can successfully see the successful operation of the program, then the next event I think should be asked why. It seems so much easier to understand and master.The concept of the socket program
What is a bitwise operation
Bitwise operators are operated in binary, which can only be used for integer-type operations. such as: Char,short,int,long
bitwise operators are used to get high and low values
int a=0x1234;
int high,low;
High = (a>>8
Destructors in C #by Ansil
Introduction
In the Enterprise application development world, the buzzwords are performance, scalability, and security. I started my career as a VC programmer, and one fine morning, I was transferred to WEB Development
believe that a lot of people have played 2048, a simple and interesting digital game, has seen many people playing on the subway to play to go, feel very interesting, then download a play for a while, but never break the "2048", see some small
strcat (connecting two strings)Related functionsbcopy,memccpy,memcpy,strcpy,strncpy
Table header File#include
Defining functionsChar *strcat (char *dest,const char *src);
Function descriptionstrcat () copies the parameter src string to the end of
This is a class strcoding (strCoding.h file)#pragma once#include #include #include using namespace Std;
Class Strcoding{PublicStrcoding (void);~strcoding (void);void utf_8togb2312 (String &pout, char *ptext, int pLen);//utf_8 to gb2312void
one, let oneself become accustomed to C + +
Item1. View C + + as a language Federation
C + + consists of the following parts: C, object-oriented C + +, Template C + +, STL
Item2. Try to replace #define with const, enum and inline.
Item3. Use
Because of the original C-style violence universal type conversion is easy to cause run-time errors, so to introduce classification more clearly in advance to find the wrong conversion syntax. The type conversion of an object contains a reference or
In C # arrays, Arraylist,list can store a set of objects, so what is the difference between the three? Array
The first occurrence of an array in C #. is stored continuously in memory, so it is indexed very quickly, and it is easy to assign and
Google for a long time did not find the right, in fact, I only need a function, can calculate the MD5 value of the file is good,
Later found the source files of Md5.h and md5.c, modeled on other people's encapsulation of a function (he that has a
For example, I have A.cpp, A.h, main.cpp three files.
To compile a linked C + + code:
First step: g++-C A.cpp main.cpp
This allows you to compile A.cpp and main.cpp code generation A.O and MAIN.O files "because A.cpp contains A.h header files, so
0. Foreword
The article is longer, and the content is relatively boring, I hope that the memory layout of C + + objects, virtual table pointers, virtual base class pointers have in-depth understanding of friends can slowly look. The conclusions of
1. Declare global variables in Header1.h, header1.cpp define global variables
Header1.h
#ifndef header1_h_
#define HEADER1_H_
extern int g_n;//header file must have extern declaration global variable, no value
//int g_ o; error
//int g_o = 10;
Conceptvoid pointer data pointer
void Pointer
Basic concepts of void pointers
void means "no type", and void pointer is "No type pointer", and a void pointer can point to any type of data.
so void pointers are generally referred to as universal
The following is a detailed analysis of the four operators in C + + that cannot be overloaded as friend functions, the need for friends can come to the reference
The C + + rule has four operators =,,, [], () cannot be an overload in the global
Two class with pointer members (class String)
1. Test code (use effect)
int main ()
{
string S1 (),
string s2 ("Hello"); Constructor
String S3 (S1); Copy construction
cout
2 Big Three (three kinds of special
The concepts of references and pointers in C + + are often compared, and there are very similar characteristics between them. This brings trouble to beginners, especially when many compilers use pointers to implement references, adding to the
Before we start talking about threads, let's take a look at the carrier of the thread-the process. Process, which is an instance of a running program, is an execution activity of a program in its own address space. A process is the basic unit of
This procedure is to use the adjacency table to represent the depth of the first search, for the algorithm introduction 22.3 pseudo code of C + + implementation.
For a graph to get the correct results, for the graph can also seem to get traversal
Record every day of learning, from zero to one. Stick with you and me.Read a lot of books, still not programmed, from entering a pit in to another pit. In fact, very helpless, but there is no way.Perhaps, you need a good thought process. Time will
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