C + + string processing problem

1, Title 1.1 Title picture 1.2 Title Document #include <iostream> #include <ctime> using namespace std; //Define a type def that will be very useful when we implement our functions. typedef char* charPointer; //This type def will make cstring parameter passing by reference easy to debug //Example void foo(charPointer& x) ...

Posted by powerpants on Sat, 05 Mar 2022 01:48:14 +0100

Non zero basic accelerated Go language_ Basic chapter

Non zero basic accelerated Go language_ Basic chapter There is no need to install the Go environment here. It is recommended that you prepare the Goland + Go environment Here are the features of all languages. See what's different about Go Plastic subdivision In Go language, integer types can be subdivided into 10 types int ...

Posted by leebo on Sat, 05 Mar 2022 01:29:52 +0100

Data structure and algorithm linear table

Linear table Definition of linear table: A finite sequence consisting of n(n ≥ 0) data elements (a1,a2,..., an).Record as: L=(a1,a2,..., an) ai-1 is the direct precursor of ai, and ai+1 is the direct successor of ai a1 - first element - it has no precursor an -- tail element - it has no successorTable length: the number of elements in a li ...

Posted by Bobulous on Sat, 05 Mar 2022 01:22:48 +0100

[advanced pointer application (Simulated Implementation of qsort sorting function)]

preface: 🐱 ‍ 🏍 Ha ha, I'm very glad that you have entered my series of articles on pointer learning. I believe that in the process of learning pointer, most of your little partners must not be plain sailing. Once you learn it, you know that there may be a stagnation in one of these links. I think so as a Xiaobai, but no matter what, y ...

Posted by epimeth on Mon, 21 Feb 2022 15:14:22 +0100

How to use C + + pointer correctly

Smart pointer When using heap memory, when a piece of heap memory is no longer needed, this memory must be released in order to reallocate this memory. If a programmer accidentally makes an error when writing code for object reallocation, it will lead to serious problems, such as memory leakage, which will lead to program crash. In C ++ 11 ...

Posted by robin339 on Sat, 19 Feb 2022 12:57:30 +0100

(c + + growth record) - C + + cast operators (static_cast, reinterpret_cast, const_cast and dynamic_cast)

C + + cast operator appendix Encyclopedia of professional vocabulary C languageC++PointerCast type reference Statement: some of the contents of this article are directly from references and are subject to infringement and deletion. C + + cast operators (static_cast, reinterpret_cast, const_cast and dynamic_cast) summary In my daily ...

Posted by batfastad on Sat, 19 Feb 2022 01:50:39 +0100

C language string

C language string I character string 1. It is composed of a group of consecutive characters and is contained with "", and the last character must be '\ 0', which indicates the end of the string, and the ASCII code of '\ 0' is 0 Note: To study a string is to study the characters one by one 2. The memory space occupied by t ...

Posted by blufish on Fri, 18 Feb 2022 13:35:37 +0100

STL container: dual end queue deque and priority queue priority_queue

Double ended queue deque deque is a double ended queue, which can be inserted at the head and tail, or deleted at the head and tail. Its advantage is that it combines the advantages of vector and list, but realizes random access and header plug deletion. When the space is not enough and needs to be expanded, it does not need to be as compl ...

Posted by chadtimothy23 on Fri, 18 Feb 2022 12:12:55 +0100

Pointer-Pointer Array, Array Pointer

Part1: Pointer Array Usage Low-level Write Output Normal Earlier, pointer arrays were mentioned as arrays, which hold pointers. Why does this happen? When we want to give many addresses to a pointer variable, we need a write, which is too cumbersome. The pointer array solves this problem. Take a look at the use of pointer arrays: and definin ...

Posted by subcool on Sun, 13 Feb 2022 18:21:06 +0100

Fledgling Xiao Li's 102nd blog talk about function pointers

Function pointer digression A function is a function A pointer is a pointer Pointer function is a function Function pointers are pointers The essence of function pointer The essence of function pointer is pointer, the essence of pointer is address, and the object pointed to by function pointer is a function. The function pointer is generally ...

Posted by SsirhC on Thu, 10 Feb 2022 00:38:29 +0100