Tag:Pointer

  • Introduction to redis data structure part 2 – table skipping

    Time:2021-6-14

    This article uses the “signature 4.0 International (CC by 4.0)” license agreement. You are welcome to reprint or modify it, but you need to indicate the source.Signature 4.0 International (CC by 4.0) Author: nicksxs Created on: January 4, 2020 Link to this article:Introduction to redis data structure part 2 – table skipping Skip list Jump […]

  • Null pointer and void pointer in C language

    Time:2021-6-12

    Null pointer and void pointer in C languageShuimanting520 2016-05-10 07:12:12 18926 collection 30Category column: C / C + + article tag: C + + pointer void nullcopyrightNull pointer nullIn C language, if a pointer does not point to any data, we call it a null pointer, which is represented by null. For example: int *p […]

  • What is the structure of redis key value pair?

    Time:2021-6-12

    What is the structure of redis key value pair? A global hash table (array) is composed of multiple hash buckets (elements on the array, including entry elements) For example, key name: AAA, key value: BBBThrough hash (AAA), get array subscript 6, then hash bucket 6. The entry element in hash bucket 6 containsKey andValue pointer,Key […]

  • C + + Object Oriented Advanced Programming learning notes! Eat ash series, take it to collect!

    Time:2021-6-11

    ◇ vptr&vtbl Object has a virtual function pointer in memory, which generally exists before the data member. The virtual function pointer points to the virtual function table, in which the address of the virtual function is stored in the order of function declaration. We can use (* (P – > VPTR) [n]) (P); Or (* P […]

  • Rust learning – when to put data on the heap

    Time:2021-6-10

    When to put data on the heap Cognitive ownership, Life cycle and reference validity, Smart pointerThese three chapters are related. Ownership and life cycle ensure the validity of data. Smart pointer data is stored on the heap and the pointer is on the stack. Suggestions in the book When there is a type of unknown […]

  • The usage of input output conversion specifier in C language

    Time:2021-6-9

    The usage of input output conversion specifier in C language This paper mainly introduces the usage of conversion specification in formatted input and output statements in C language printf sprintf fprintfConversion specifier for % [flags][width][.precision][length]specifier flags meaning – Align left + When the signed value is positive, a positive sign is added before the value; […]

  • ThreadX — message queue of IPC application

    Time:2021-6-7

    Author:zzssdd2 E-mail:[email protected] 1、 Application Introduction Message queuingIt is a common way of data communication in RTOS, which is often used for data transmission between tasks or between interrupts and tasks. In bare metal systems, we usually use global variables to transfer data. For example, after an event occurs, we change the data and set flags […]

  • Learning notes of C + +

    Time:2021-6-7

    Quotation: it is a kind of rhetorical device, which refers to the words of famous people, or the things, things, poems, allusions, fables, idioms, proverbs, proverbs, etc. of famous people to support the author’s position, so as to prove and strengthen his theory and enrich the content of the article [1].–Wikipedia In C + +, […]

  • [C language programming] C language integer reverse order output program!

    Time:2021-6-6

    An integer input from the keyboard is stored in an array, and the integer is output in the reverse order of the array through the operation of the program. The problem is solved by recursion.   Algorithmic thinking Design function to store data in reverse order, set the address of formal parameter array to receive […]

  • C language pointer

    Time:2021-6-5

    (1) Pointer knowledge forerunner 1. Memory space and memory address int num=100;Data in computer is stored in memory, so the essence of reading and writing data is actually reading and writing memory. At present, the only way to read and write memory is through variable name, which is called “direct access” memory. In a computer, […]

  • Introduction to leetcode

    Time:2021-6-4

    This paper includes eight topics, which come from the simple difficulty of leetcode. Each problem will be given two solutions. The first one is more violent and easy to understand, and the second one is more efficient. We will try our best to avoid using Python’s built-in functions, so that we can really understand the […]

  • leetcode 151. Reverse Words in a String

    Time:2021-6-4

    Title Requirements Given an input string, reverse the string word by word. For example, Given s = “the sky is blue”, return “blue is sky the”. Update (2015-02-12): For C programmers: Try to solve it in-place in O(1) space. click to show clarification. Clarification: What constitutes a word? A sequence of non-space characters constitutes a […]