STM32 MDK off chip FLASH download algorithm -- Based on QSPI (W25Q32)

preface The chip STM32H750 is used in a recent project. Its on-chip flash is only 128KB in size (although it is said on the Internet that it actually has 2MB as H743, this method is not used for insurance). Because the project uses RTOS, LWIP, TLS, etc., and the generation program is relatively large, W25Q32 (4MB in size) is added as off chip ...

Posted by Keith Scott on Fri, 04 Feb 2022 06:09:23 +0100

Codeforces Round #753 (Div.3) A~D problem solution

Codeforces Round #753 (Div.3) A~D problem solution A. Linear Keyboard meaning of the title Given a keyboard composed of 26 lowercase letters in a certain order, each group gives a word, and calculates the distance that the hand moves to complete the word. thinking First, create two strings a and s to store the keyboard and words respective ...

Posted by willeadie on Fri, 04 Feb 2022 05:25:56 +0100

Community discovery algorithm - KL algorithm

K-L (Kernighan Lin) algorithm Original paper( An efficient heuristic procedure for partitioning graphs) K-L (Kernighan Lin) algorithm is a dichotomy method that divides a known network into two communities of known size. It is a greedy algorithm. Its main idea is to define a function gain Q for network partition. Q is the difference between ...

Posted by Jack_Slocum on Fri, 04 Feb 2022 03:30:40 +0100

Day12-Recursive+Tree

Title Source: LeetCode LeetCode Month Emblem Title of the Day 1414. and the minimum number of Fibonacci numbers for K Give you the number k, and return the smallest number of Fibonacci numbers for k, where each Fibonacci number can be used multiple times. The Fibonacci number is defined as: F1 = 1 F2 = 1 Fn = Fn-1 + Fn-2, where n > 2. T ...

Posted by jcarver on Thu, 03 Feb 2022 21:04:43 +0100

python brush title--sum of N numbers problem (double pointer + pruning)

1. Sum of two numbers (double pointer) This was done earlier, using a hash table, with a time complexity of N But if you change your mind and use the double pointer you learned today, it will be easy to understand, although it will not decrease or increase in time complexity (the sorting complexity is NlogN). Idea: Sort first to get an order ...

Posted by taskagent on Thu, 03 Feb 2022 18:57:56 +0100

Algorithmic design and analysis of double-ended monotonic queues (sliding window problem) and monotonic stacks

Dual-ended monotonic queue (sliding window problem) Basic concepts: windows (on the basis of arrays) (1) There is a left boundary for L and a right boundary for R, initially all on the leftmost side of the array (2) When moving: L or R can only move to the right (3) L must always be on the left side of R (4) R moves elements right into the ...

Posted by padma on Thu, 03 Feb 2022 18:46:27 +0100

Leetcode algorithm interview sprint practice 11 (queue)

40. Implement queue with stack As stated in the title, you can only use two stacks to implement some operations of the queue. The queue should support push(element), pop() and top(), where pop is the first (foremost) element in the pop-up queue. Both pop and top methods should return the value of the first element. class MyQueue: ...

Posted by rcarr on Thu, 03 Feb 2022 09:56:47 +0100

Quick sorting with qsort function

catalogue 🍈🍈Foreword 🍈🍈A brief introduction to qsort 🍈🍈Using qsort to realize a sort of integer type 🍈🍈Sorting of structures with qsort function 🍈🍈Implementation of qsort function   📢 preface Share a library function today This paper introduces the use and implementation of qsort It can realize sorting that is not limi ...

Posted by deregular on Thu, 03 Feb 2022 08:37:33 +0100

JavaScript implementation prefix tree

brief introduction Prefix tree is also called word lookup tree, Trie tree , is a kind of tree structure , is a variant of hash tree. The typical application is to count, sort and save a large number of data character String (but not limited to string), so it is often used by search engine system for text word frequency statistics. Its advantag ...

Posted by All4172 on Thu, 03 Feb 2022 08:25:55 +0100

[LeetCode] - hash table

preface When I first know LeetCode and algorithm, I will record my algorithm learning experience in this series of articles. In the early stage, I mainly supervise my learning and clock in. In the later stage, I will slowly add my understanding of knowledge to the articles. I hope you can gain something from reading my articles. The order ...

Posted by hoboman on Thu, 03 Feb 2022 08:15:49 +0100