[untitled] Pointer passing and reference passing in parameter passing

Value transfer: A formal parameter is a copy of an argument. Changing the value of a formal parameter does not affect the value of an external argument. From the perspective of the called function, the value transfer is one-way (argument - > formal parameter), and the value of the parameter can only be passed in, Cannot transfer out. When ...

Added by ScoTi on Sun, 16 Jan 2022 16:17:44 +0200

202106C language level 2 true question

Digital amplification Given an integer sequence and magnification x, each integer in the sequence is amplified by x times and output. Time limit: 1000 Memory limit: 65536 input It contains three lines: the first line N represents the length of the integer sequence (N ≤ 100); The second line is N integers (not exceeding the integer range), ...

Added by james19 on Sun, 16 Jan 2022 15:47:28 +0200

Figure C + + implementation of template, BFS and DFS

chart There are two ways to store graphs: adjacency matrix and adjacency table. adjacency matrix A two-dimensional array is used to indicate whether there are edges between vertices and how much weight the edges are. For an undirected graph, the adjacency matrix is a symmetric matrix. The disadvantage is that although the adjacency matrix i ...

Added by tallberg on Sun, 16 Jan 2022 11:44:12 +0200

Various knowledge of C (small synthesis)

Tip: After the article is written, the catalog can be generated automatically, how to generate the help document to the right Formatting Characters in C %c:Single Character %d:Decimal integer(int) %ld:Decimal integer(long) %f:decimal(float) %lf:decimal(double) %o:Octal Number %s:Character string(char) %u:Unsigned decimal n ...

Added by Pyro on Sun, 16 Jan 2022 08:36:36 +0200

Object oriented programming -- Inheritance

1, Purpose of the experiment: Master the concept of inheritance.Understand different inheritance types. 2, Experiment content: On the basis of previous experiments, Design a base class Account to express the commonness of all accounts, and then change the SavingsAccount class into its derived class. In addition, it also derives the class Cre ...

Added by smsharif on Sun, 16 Jan 2022 07:19:20 +0200

UE4 HTML5 C++ intermodulates with JS (source version 4.22)

Catalog 1. js C++. 1.c++ Declaration: 2. Modify HTML5ToolChain.cs file 3. Modify project_template.js file 4. Call 2. Calling js by C++. 1. Inline 1) EM_JS Call:  2)EM_ASM: 3) EM_ASM_INT, EM_ASM_DOUBLE Has Return Value Method 2.emscripten_run_script()  3. Modify Source Code 1) In HTML5 JavaScriptFx. C++ function added in H extern &q ...

Added by sahel on Sun, 16 Jan 2022 07:08:29 +0200

Container adapter -- queue, stack, priority_queue

What is an adapter adapters play the role of bearing and converter in the flexible combination and application function of STL components. The concept of adapter is actually a design pattern. In the design pattern, the definition of adapter style is as follows: convert one class interface into another class interface, so that classes that ...

Added by slyte33 on Sun, 16 Jan 2022 07:00:39 +0200

LeetCode -- Target Sum -- backtracking algorithm and dynamic programming -- alloc and mismatch -- the best explanation for non aftereffect and repetitive subproblems

Title Description You are given an integer array nums and an integer target. You want to build an expression out of nums by adding one of the symbols '+' and '-' before each integer in nums and then concatenate all the integers. For example, if nums = [2, 1], you can add a '+' before 2 and a '-' before 1 and concatenate them to build th ...

Added by cahamilton on Sun, 16 Jan 2022 01:31:57 +0200

QT from entry to soil -- file reading and writing operation

introduction File reading and writing is a function of many applications, and even some applications are developed around the processing of files in a certain format, so file reading and writing is a basic function of application development. Qt provides two basic methods for reading and writing plain text files: Use the IODevice read-write f ...

Added by Sirus121 on Sun, 16 Jan 2022 00:57:43 +0200

100 line process pool realized by C++11

Thread pool C + + has thread operation and asynchronous operation, which means there is no thread pool. As for the concept of thread pool, I'll first search other people's explanations: Generally speaking, the thread pool has the following parts: One or more threads that complete the main task. Management thread for scheduling management. ...

Added by chris_2001 on Sun, 16 Jan 2022 00:48:53 +0200