js Learning from the Past and Learning from the New 3 --- Learning Liao Xuefeng's js Course

1.map Because the map() method is defined in JavaScript Array, we call Array's map() method and pass in our own function, and we get a new Array as a result: function pow(x) { return x * x; } var arr = [1, 2, 3, 4, 5, 6, 7, 8, 9]; arr.map(pow); // [1, 4, 9, 16, 25, 36, 49, 64, 81] The parameter passed in by map() is pow, which is the func ...

Posted by saku on Mon, 15 Apr 2019 01:03:31 -0700

Asymmetric Encryption of Encryption Algorithms

The previous article introduced the principle of symmetric encryption, but its biggest problem is that the encryption and decryption keys are the same, and can not guarantee that the key can be safely delivered to both sides, even if it is safely delivered to both sides, there will inevitably be "undercover" inside. Asymmetric encrypt ...

Posted by Desdinova on Sun, 07 Apr 2019 20:03:31 -0700

Coursera Programming and Algorithms Course 1. Introduction to Computing and Tenth Week Assignment of C Language Foundation (Part 1)

Recently, in the use of spare time and Coursera, we have attended a special course of Programming and Algorithms in Peking University, a total of seven courses, which is the first course of Introduction to Computing and C Language Foundation. Programming Question #1: Number of letters Source: POJ (Coursera Statement: Exercises completed on PO ...

Posted by oscardog on Sat, 30 Mar 2019 23:33:29 -0700

One linux command per day: xargs of find command

When processing matched files with the - exec option of the find command, the find command passes all matched files together to exec for execution. But some systems limit the length of commands that can be passed to exec, so that overflow errors occur after the find command runs for a few minutes. Error messages are usually "parameter col ...

Posted by d~l on Tue, 26 Mar 2019 06:36:29 -0700

One linux command per day: gzip command

Reducing file size has two obvious advantages: one is to reduce storage space; the other is to reduce transmission time when transferring files over the network. Gzip is a command used frequently in Linux system to compress and decompress files, which is convenient and easy to use. Gzip can be used not only to compress large and less used file ...

Posted by Zallus on Tue, 26 Mar 2019 04:09:31 -0700

C++ explicit keyword details

First, the explicit keyword in C++ can only be used to modify a class constructor with only one parameter. Its function is to show that the constructor is displayed, not implicit. The other key corresponding to it is implicit, meaning hidden. Class constructors are declared implicit by default. So what's the difference between a constructo ...

Posted by Adam W on Mon, 25 Mar 2019 20:54:29 -0700

javascript regular expressions

Why do we need regular expressions? Regular expression (RegExp) How to find the content quickly according to certain rules, the designers of js provide us with a RegExp object, which is specially used to deal with similar problems. RegExp objects represent regular expressions and are powerful tools for pattern matching of strings. Regular E ...

Posted by kf on Mon, 25 Mar 2019 11:12:30 -0700

Data Structure Skills Examination System

Through one month's efforts, the data structure skills examination system was finally implemented in C++ language (including C language interpolation). The greatest advantage of the system is that it can detect whether students have inserted U disk when answering questions, and open auxiliary tools such as word and notebook. This system is divi ...

Posted by briant on Wed, 20 Mar 2019 17:15:27 -0700

leetcode programming record 1#8String to Integer (atoi)

Today is the first time to record the problem-solving process on leetcode. Let's start with the first question: String to Integer (atoi) Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below and ask yourself what are the possible input cases. ...

Posted by razz on Wed, 13 Feb 2019 12:18:19 -0800

CSU-ACM2017 Summer Training 1-Debug and STL C-Languages

C - Languages The Enterprise has encountered a planet that at one point had been inhabited. The only remnant from the prior civilization is a set of texts that was found. Using a small set of keywords found in various different languages, the Enterprise team is trying to determine what type of beings inhabited the planet. Input The first l ...

Posted by ljzxtww on Tue, 12 Feb 2019 22:24:20 -0800