• JS advanced – traversing DOM tree


    Traversing DOM tree   The first function: give me the root node, and I will find all the child nodes: fordom (root node) Get the children of this root node Var children = children of the root node Call the second function The second function: give me all the children, and I will display the […]

  • Maven – package dependent jar packages into project jar packages


    Preface: Sometimes in project development, many dependent jar packages are needed, and the dependent jar packages also depend on other jar packages, which makes the management of jar packages easy to be incomplete. There are two ways to avoid this problem. 1、 Configure in pom.xml file, and put the dependent jar package into the specified […]

  • [leetcode algorithm weekly] issue 5


    The official account of WeChat’s public front growth story is written in 2019.12.06. background This paper records the whole thinking process in the process of writing questions for reference. The main contents include: Assumption of topic analysis Write code validation Consult others’ solution Thinking and summing up Catalog 100. Same tree 101. Symmetric binary tree […]

  • Redis underlying data structure


    Simple dynamic string SDS Include string length, remaining available length, character array Used for all thestringstorage Dictionary (map) Array + linked list, similar to HashMap Solving hash conflict by chain address method Rehash uses the new hash array linked list for data rehash migration. The capacity expansion is the first 2 n power greater than […]

  • How to achieve the safe backup and 1GB / s fast recovery of 10t cluster data?


    Author: Shen Taining As an infrastructure, the security of database is not clear, so the data security backup and recovery function is standard in serious use scenarios. As a distributed database, tidb can meet the backup and recovery needs of large clusters. After testing, the backup and recovery speed of 10t data can reach GB […]

  • The practice of K-means clustering algorithm in tensorflow


    Original address: here Google recently opened its second-generation artificial intelligence and numerical computing library tensorflow. Tensorflow is developed by the Google brain team and can run flexibly on multiple platforms, including GPU platforms and mobile devices. The core of tensorflow is to use the so-called data flow. You can refer to the knowledge about genetic […]

  • “Linked list” of data structure


    What is a linked list? Linked list is a kind of linear list, but it does not store data in linear order, but stores the pointer to the next node in each node. Therefore, it does not need to allocate continuous storage space, and does not need to fix the size of elements in advance. […]

  • Recursively load provinces and cities to TreeView


    The recursive loading of provinces and cities into treeview is just a representation of recursion. Using recursion can achieve many functions, similar to our local Disk directory file loading and so on is the principle, very convenient.   In the future, the directory loading, adding, deleting, modifying parent-child nodes and so on will be attached

  • Realize the real-time statistics of massive billions of data by Flink


    background Message report is mainly used to count the distribution of message tasks. For example, the total number of APP users who send a single push message, the number of successfully pushed mobile phones, and how many app users click the pop-up notification and open the app, etc. Through the message report, we can directly […]

  • Using go to write / zero to implement distributed cache geecache in 7 days


    Catalog Day 1: LRU cache retirement strategy | code – GitHub Day 2: single machine concurrent cache | code – GitHub Day 3: http server | code – GitHub Day 4: hash | code – GitHub Day 5: distributed node | code – GitHub Day 6: prevent cache breakdown | code – GitHub Day 7: […]

  • JDK source code: red black tree foundation 2


    When it comes to HashMap, we must talk about the red black tree. As a self balanced binary search tree, the red black tree is a widely used data structure. In JDK1.8, the red black tree is used to improve the performance of HashMap. Today, when it comes to the red black tree, we have […]

  • Redis cluster building ~ redis-x64-3.2.100


    Reference documents: https://www.cnblogs.com/yaopengfei/p/12418227.html https://blog.csdn.net/weixin_42694286/article/details/92974535 https://blog.csdn.net/qq_42815754/article/details/82912130 https://blog.csdn.net/u010963948/article/details/78963572   1. Configure redis service Download redis-x64-3.2.100 in ZIP format, unzip it to the root directory of disk D, and then copy 6 configuration files, namely 6279 ~ 6384Download Directory: https://github.com/msopentech/redis/releases/ The contents of the main configuration file are as follows: take [redis. Windows-service6379. Conf] as an example, the […]