C++ Threads and Future, Promise Templates
stay Multithreaded In programming, data sharing is required, such as when one thread needs to use data generated by another thread's operations.
When asynchronous programming is involved, thread-to-thread synchronization is sometimes required, for example, when an asynchronous subscription message is executed, the thread that processes the mes ...
Posted by phwae on Fri, 12 Nov 2021 21:56:25 +0100
AudioTracK for Android 11 Audio framework exploration
In the previous article, we introduced the startup and initialization of AudioPolicyService and AudioFlinger services. Here's a look at what AudioTrack and AudioFlinger did.
MediaPlayer will create the co ...
Posted by dstockto on Fri, 12 Nov 2021 17:47:12 +0100
C++ Linear Table (Nursery level teaches you from 0 to encapsulating a SeqList class)
[Eager to get the code directly]
(Linear Table (Non-Linked Table) Source Disk Link: https://pan.baidu.com/s/1SbzGBK0Cv3nV3q14yUhDBw Extraction code: s51t
Chain List Source Disk Link: https://pan.baidu.com/s/1dhd7Lvcd3yhC5nzcVzWTyA Extraction Code: zdzn )
1. What is a linear table
& ...
Posted by tester2 on Thu, 11 Nov 2021 17:53:43 +0100
c + + < set > set() usage
There are several questions about set:
(1) Why is the insertion and deletion efficiency of map and set higher than that of other sequence containers?
Most people say that it is very simple, because there is no need to copy and move memory for associated containers. Yes, indeed. All elements in the set container are stored in the form o ...
Posted by pabs1983 on Thu, 11 Nov 2021 09:34:13 +0100
Dichotomy details, the choice of boundaries is distressing
Reference link: https://blog.csdn.net/xiao_jj_jj/article/details/106018702
Dichotomy finding complexity usage scenarios
1, Find whether to include a number
prerequisite: 1. Ordered sequence 2. No duplicate numbers
Example: force buckle 704 Given an n-element ordered (ascending) integer array nums and a target value target, write a funct ...
Posted by bodge on Wed, 10 Nov 2021 22:07:13 +0100
C + + foundation - array
1. Array in CPP
C + + supports array data structures, which can store an ordered collection of elements of the same type with a fixed size. Array is used to store a series of data, but it is often regarded as a series of variables of the same type.
The declaration of an array is ...
Posted by samudasu on Tue, 09 Nov 2021 22:20:17 +0100
project command of common Cmake commands
2. project()
1.1 command format:
Form 1:
project(<PROJECT-NAME> [<language-name>...])
Form 2:
project(<PROJECT-NAME>
[VERSION <major>[.<minor>[.<patch>[.<tweak>]]]]
[DESCRIPTION <project-description-string>]
[HOMEPAGE_URL <url-string>]
[LANGUAGES <lan ...
Posted by wigz01 on Tue, 09 Nov 2021 08:49:47 +0100
C++ Primer Plus Learning Notes
Chapter IV. Composite Types
5. Commons
Usage is the same as structure, the main difference is that all elements in the structure allocate memory, and the common body (union) is that all elements share a single memory, that is, only one type can be represented at a time, and the size is the largest type.
union one4all // Size is the length ...
Posted by jl5501 on Mon, 08 Nov 2021 17:21:33 +0100
Installation and use of boost library under windows
What is the boost library
In short, the Boost library is some of the extensions to the C + + language standard library C++ The general name of the program library is developed and maintained by the Boost community organization. The Boost library works perfectly with the C + + standard library and provides extend Function.
Many features of C + + ...
Posted by prasanthmj on Mon, 08 Nov 2021 16:46:02 +0100
Stack and queue 6: sliding window maximum
Problem Description:
Title Link: Sliding window Max
Give you an integer array nums, with a sliding window of size k moving from the leftmost side of the array to the rightmost side of the array. You can only see k numbers in the sliding window. The sliding window moves only one bit to the right at a time. Returns the maximum value in the s ...
Posted by kidestranged on Mon, 08 Nov 2021 13:40:33 +0100