linux system programming thread
What is a thread
A process does only one thing at a time. With multiple control threads, the process can be designed to do more than one thing at the same time, and each thread handles independent tasks. Process is an instance of program execution and the basic unit for allocating system resources. In the system of thread oriented design, ...
Added by JAM on Fri, 14 Jan 2022 11:26:01 +0200
JNI/NDK Development Guide -- C/C + + accessing Java instance variables and static variables
In the previous chapter, we learned how to access static methods and instance methods in any Java class in local code. In this chapter, we also learned how to access and modify instance variables and static variables in Java through an example. Static variables, also known as class variables (attributes), share the same data in all instance obj ...
Added by svan_rv on Fri, 14 Jan 2022 09:10:09 +0200
C language learning notes - sorting and searching
1. Introduction of sorting algorithm
Sorting is also called sort algorithm. Sorting is the process of arranging a group of data in a specified order
1.1 classification of sorting
(1) Internal sorting: refers to loading all data to be processed into internal memory (memory) for sorting
(2) External sorting: the amount of data is too la ...
Added by Zay on Fri, 14 Jan 2022 03:18:21 +0200
Detailed explanation of C language callback function
1. What is a callback function?
Callback functions are taller than ordinary functions just by their names. What is a callback function? I'm sorry I haven't read much, but I didn't see the definition of callback function in that book. I searched Baidu and found that there are different opinions. A large part of them use a similar scene to expla ...
Added by haolan on Thu, 13 Jan 2022 22:25:50 +0200
Unmanned CPP shared pointer
Unmanned CPP shared pointer
Usage of shared pointers
The shared_ptr is provided in the current Boost library and should be a template class provided in the standard library of C++1x in the future. Previously, the "auto_ptr" in the ISO/IEC 14882:2003 standard library had similar functions. Obviously shared_ PTR is better than auto_ P ...
Added by amitkrathi on Thu, 13 Jan 2022 20:05:26 +0200
c language bits and pieces
catalogue
1, What is C language?
2, Common keywords
1. Keyword typedef
2. Keyword register
3, Data type
IV. ASCII code table
5, Variable type
1. Global variables
2. Local variables
6, Constants in C language
1. Literal constant
2.const modified constant
3.# Identifier constant defined by define
4. Enumeration con ...
Added by vaavi8r on Thu, 13 Jan 2022 18:52:30 +0200
Data structure linear table
Question 1: sequence table insertion
[problem description] Let the data elements in sequence table A increase in order, try to write A program to insert x into the appropriate position of the sequence table so that the table is still orderly. [input] Initial sequence table, insert position, insert element. [output] Sequence table after ins ...
Added by vonnero on Thu, 13 Jan 2022 15:54:00 +0200
Basic concepts of C language pointer
1, What is the pointer?
In computer science, pointer is an object in programming language. You can use the address to find a value that points to another place in the computer memory. Since the variable unit can be found through the address, it can be simply said that the address points to the variable unit. Therefore, the address visualiz ...
Added by oneski on Thu, 13 Jan 2022 11:56:11 +0200
First knowledge of C language [3]
6 selection statement
int main()
{
int coding = 0;
printf("Please enter 0 or 1:\n");
scanf("%d",&coding);
if (coding == 1)
printf("true");
else
printf("false");
return 0;
}
7 circular statement
while statementfor statementdo-while Statements
int main() {
int iq = 0;
printf("Please enter your iq: \n");
while (scanf("%d\n" ...
Added by scoman on Thu, 13 Jan 2022 11:48:36 +0200
C. Division by Two and Permutation
Catalog
C. Division by Two and Permutation
A. Plus One on the Subset
B. Make AP
C. Division by Two and Permutation
Topic Description
Interpretation
Given a n array of size n, you can do something like delete a and put a/2 (rounding down) into the array. We can do this many times and output YES if we can get a full permutation ...
Added by DaveTomneyUK on Wed, 12 Jan 2022 22:59:51 +0200