LeetCode brush notes linked list traversal linked list

160 intersecting linked list Given two linked lists, judge whether they intersect at a point, and find the intersection node. The input is two linked lists and the output is one node. If there are no intersecting nodes, an empty node is returned. Input: intersectVal = 8, listA = [4,1,8,4,5], listB = [5,0,1,8,4,5], skipA = 2, skipB = 3 Out ...

Posted by suvarthi on Wed, 10 Nov 2021 19:12:06 -0800

[UE4 C + +] octree implementation and visualization

preface Implementation version of this article: 4.26 See the end for reference Article address https://www.cnblogs.com/shiroe/p/15534304.html concept definition Octree (English: octree) is a tree data structure. Each internal node has exactly eight child nodes. Octree is often used to segment three-dimensional space and recursively subdivi ...

Posted by Chris_Evans on Wed, 10 Nov 2021 18:01:51 -0800

Multi school sprint NOIP simulation 27 - Super doubling - reconstruction tree

No link is provided for this question Title Description Given a tree. We think one x → y x\rightarrow y Simple path of x → y( x ≠ ...

Posted by phpnewbie911 on Wed, 10 Nov 2021 08:11:15 -0800

Judge whether it is a balanced binary tree - js

01 - sum of two numbers - js describe Given an integer array numbers and a target value target, please find two subscripts in the array that add up to the target value, and the returned subscripts are arranged in ascending order. Example 1 Input:[3,2,4],6 Return value:[2,3] Note: because 2+4=6 ,And the subscript of 2 is 2, and the subscrip ...

Posted by sherri on Wed, 10 Nov 2021 08:05:06 -0800

list_files and tuple_regexp_select function

#Get image read_image(Image,'E:/C/Halcon/1.jpg') #Read images of the entire folder #1 list the files in the specified path list_files('E:/C/Halcon',['files','follow_links'],ImageFiles) #2. Select qualified documents tuple_regexp_select(ImageFiles,['\\.(tif|tiff|gif|bmp|jpg|jpeg|jp2|png|pcx|pgm|ppm|pbm|xwd|ima|hobj)$','ignore_case'],ImageFiles) ...

Posted by plezops on Wed, 10 Nov 2021 07:13:45 -0800

Learning notes: tree chain subdivision

preface Tree chain subdivision divides the edges of the tree into many chains, so as to reduce the complexity of modifying queries on the tree. This is an introduction to light and heavy chain segmentation. Concept: Heavy son: the son with the most nodes in the subtree. If the subtrees of two sons are the same, then any one of them. Light son: ...

Posted by FuriousIrishman on Wed, 10 Nov 2021 05:51:17 -0800

On the hierarchical traversal of binary tree and the extension of written test questions (data structure)

1, Hierarchical traversal of binary tree It is unrealistic to traverse directly, because there are more nodes in the future, and not all nodes in each layer are 2k-1. If you traverse a node, save the child of the node and get it from the structure next time. Here, the child is saved in a queue (the node first placed in the space is ...

Posted by jwcsk8r on Tue, 09 Nov 2021 11:38:05 -0800

Niuke challenge 48 E Speed Forwarding (tree over tree)

Link: E-speed forwarding_ Niuke challenge 48 (nowcoder.com) The given length is n n Sequence of n a a a. Altogether m ...

Posted by somenoise on Tue, 09 Nov 2021 03:55:05 -0800

Persistent segment tree

Before talking about the persistent segment tree, you need to know what the segment tree is. If you still don't know the segment tree, you can take a look at the template I wrote about the segment tree and attach the blog address here: (63 messages) segment tree template_ AC__dream blog - CSDN blog We know that the segment tree supports modifi ...

Posted by jpraj on Tue, 09 Nov 2021 00:19:11 -0800

Task2 Python basic exercise: data structure summary

Task 2 Python basics review: data structure summary List list 1. Create a list by derivation x = [i for i in range(100) if (i % 2) != 0 and (i % 3) == 0] #[3, 9, 15, 21, 27, 33, 39, 45, 51 #, 57, 63, 69, 75, 81, 87, 93, 99] <class 'list'> 2. Since the element of the list can be any object, what is saved in the list is the pointer of ...

Posted by tyler on Mon, 08 Nov 2021 16:26:26 -0800