ES6 deconstruction, object + object API expansion, array + array API expansion
1-ES6 deconstruction: ES6 allows you to extract values from arrays and objects and assign values to variables according to a certain pattern, which is called deconstruction. The essence of deconstruction belongs to "pattern matching". As long as the patterns on both sides of the equal sign are UTF-8...
Posted by Karpathos on Mon, 27 Sep 2021 16:09:37 +0530
What are the native methods of JS arrays, so many API s are really hard to remember?
Array Native Method Combing 🔶 Array.isArray() 🔶 The method of combining arrays: concat(), which returns a stitched array without affecting the original array. 🔶 Array and string conversion methods: toString(), join(), where the join() method specifies the delimiter when converting to a strinUTF-8...
Posted by jasonla on Wed, 29 Sep 2021 22:01:28 +0530
Definition and use of arrays (Java language)
Basic usage of arrays What is an array? Array: a collection that stores a set of data of the same data type. For example, if it is an array of integer type, it can only put the data of integer type. If it is an array of double precision floating point type, it can only put the array of double UTF-8...
Posted by andreasb on Tue, 09 Nov 2021 07:30:45 +0530
Old ape talk - ArrayBlockingQueue
Guiding language In this section, let's introduce the last queue in this chapter: ArrayBlockingQueue. According to the literal translation, it is called array blocking queue in Chinese. From the name, we can see that the underlying layer of this blocking queue uses array. When it comes to arrayUTF-8...
Posted by lovasco on Sun, 08 May 2022 00:42:23 +0530
Summary of walking steps (frog jumping steps, fancy steps, etc.)
I believe that many people are first exposed to the problem of steps. Frogs jump steps, as follows: >>>A frog can jump up one step or two steps at a time. Find out the total number of jumping methods for the frog to jump up an n-step step (different results are calculated in different order) ItUTF-8...
Posted by php-pendejo on Sat, 14 May 2022 17:14:53 +0530
Find the number in the array that repeats for the first time
Description: all numbers in an array with length n are in the range of 0 to n-1. Some numbers in the array are repeated, but I don't know how many numbers are repeated. I don't know how many times each number is repeated. Please find any duplicate number in the array. For example, if you enter UTF-8...
Posted by bpat1434 on Sat, 28 May 2022 03:27:27 +0530
LeetCode - find the median of two positively ordered arrays
Topic information Source address: Find the median of two positive arrays Give two positively ordered (from small to large) arrays nums1 and nums2 of sizes m and n, respectively. Please find out and return the median of these two positive arrays. The time complexity of the algorithm should be \ UTF-8...
Posted by trg on Sat, 13 Aug 2022 22:14:53 +0530
The difference between Go language array and slice
Original link: The difference between Go language array and sliceIn the Go language, arrays and slices look similar, but in fact they have many differences. This article will talk about the differences between them.In addition, this question is often asked in interviews. It is an entry-level quUTF-8...
Posted by r3drain on Sun, 02 Apr 2023 09:38:34 +0530