Single source shortest path (c language)

Ideas: 1. Select a point V at will and record the distance from the starting point v to all points with the distance array (2) Then in the distance array, find the shortest distance from the starting point v to which point, with this point u as the intermediate, find[u]=1, prove that this point already exists ...

Added by soulrazer on Thu, 16 Jul 2020 19:16:28 +0300

offer rotation array

Moving the first elements of an array to the end of an array is called array rotation. Input a rotation of a non decreasing sort array and output the smallest element of the rotated array. For example, if the array {3,4,5,1,2} is a rotation of {1,2,3,4,5}, the minimum value of the array is 1. NOTE: all elements given are greater than 0. If th ...

Added by h3ktlk on Thu, 09 Jul 2020 18:59:09 +0300

003_ File operation of Linux common commands

1. File operation touch command Create a file. If the file name does not exist, create it directly. If it exists, change the access time touch [option] filename1 filename2... root@ubuntu:~/Test# touch hello.c root@ubuntu:~/Test# ls hello.c rm command: delete file or directory Parameter - r recursively delete subdirectories rm -rf * del ...

Added by evo4ever on Mon, 29 Jun 2020 11:43:38 +0300

Version of Django REST framework

Article catalog 1. GET parameter get version 2. URL path to get version 3. Built in version source code process 4. Built in version class 1. GET parameter to get version The RESTful specification specifies that the version can be placed on the URL, such as http://127.0.0.1:8000/api/users/?vers ...

Added by Castle on Mon, 29 Jun 2020 09:02:55 +0300

Create a custom thread pool (how to set the maximum number of threads?)

CPU intensive IO intensive 1: CPU intensive: Definition: CPU intensive also refers to calculation intensive. Programs that spend most of their time doing CPU actions such as calculation logic judgment are called CPU intensive tasks. This type of task requires a lot of calculation, which mainly consumes CPU resources. Although this kind of comp ...

Added by Arez on Sun, 28 Jun 2020 09:04:04 +0300

Code duplication experiment (deep algorithm experiment 4) report + code

Resources for all experiments Link: https://pan.baidu.com/s/1lukZRM3Rsd1la35EyyJcvg Extraction code: iv72 catalog Write in front Problem description Description of algorithm principle for solving problems Solving two lines of code similarity: LCS LCS state transition equation: LCS question: the a ...

Added by noppie on Sat, 27 Jun 2020 12:49:27 +0300

GO Manual Processing of TCP Packets

Application Scenarios Use custom communication protocol in most TCP communication scenarios image.png Sticky Packet Processing Principle: Buffer data sent by clients N times into a single packet by the size of the packet in the request header For example: Request header takes up 3 bytes (instruction header 1 byte, packet length 2 bytes), ...

Added by kellerkind on Fri, 26 Jun 2020 19:08:50 +0300

Fundamentals of Java EasyExcel - Reading

preface Always believe that good things are about to happen background Some time ago, I encountered such a problem when crawling the website data. There is a data source. Because of the large amount of data, it is not displayed on the page, only a download button is provided. Now it is necessar ...

Added by pipe_girl on Thu, 25 Jun 2020 13:20:40 +0300

"python" Object-Oriented Introduction (with diagram) in detail

Article catalog object-oriented Defining classes Define a class and create a class instance Binding instance properties for objects Creating and using instance methods Class properties Class method Static class method Construction method encapsulation General definition method: lack of concealmen ...

Added by CompuWorld on Tue, 23 Jun 2020 08:48:35 +0300

MCU platform libjpeg9 porting instructions

MCU platform libjpeg9 porting instructions With the performance of MCU platform becoming more and more powerful, it is possible to use jpeg soft decoding on MCU. This paper will explain the migration of libjpeg. libjpeg is a widely used JPEG image compression / decompression open source library, which ...

Added by milind24 on Sun, 21 Jun 2020 13:26:51 +0300