844比较含退格的字符串 Posted on 2020-04-22 Words count in article: 192 | Reading time ≈ 1 844比较含退格的字符串下面是题目 下面是题目给出的代码12345class Solution {public: bool backspaceCompare(string S, string T) { }}; 解答 还是要先判断特殊字符,在判断特殊 ... Read more »
682棒球比赛 Posted on 2020-04-22 Words count in article: 354 | Reading time ≈ 1 下面是题目 下面是题目给出的代码12345class Solution {public: int calPoints(vector<string>& ops) { }}; 因为是简单题,而且我思考的时候并没有发生很严重的卡 ... Read more »
496下一个更大的数 Posted on 2020-04-21 Words count in article: 669 | Reading time ≈ 2 496下一个更大的数下面是题目 下面是题目给出的模板123456class Solution {public: vector<int> nextGreaterElement(vector<int>& nums1, vector<int>&a ... Read more »
Javascript-8函数 Posted on 2020-04-21 Words count in article: 5.3k | Reading time ≈ 21 JavaScript-8函数概况 形参实参 this 对象的方法 构造函数 函数即对象 闭包 函数可以嵌套在其他函数中定义,这样他们就可以访问他们被定义时所处的作用域中的任何变量,这意味着Javascript函数构成了一个闭包 8.1函数定义 两种方式 函数定义表达式 函数声明语句 函数定 ... Read more »
Javascript-7数组 Posted on 2020-04-21 Words count in article: 2.4k | Reading time ≈ 9 Javascript-7数组概况 数组是值得有序集合 Javascript数组是动态的:根据需要会增长或缩减 Javascript数组可能是稀疏的:数组元素之间可以有空缺 对于非稀疏数组,lenth属性就是元素的个数 对于稀疏数组,lenth比所有元素的索引要大 7.1创建数组创建方法使用 ... Read more »
Javascript-6对象 Posted on 2020-04-21 Words count in article: 1.8k | Reading time ≈ 7 Javascript-6对象6.1创建对象123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869 ... Read more »
Javascript-5语句 Posted on 2020-04-21 Words count in article: 2.6k | Reading time ≈ 10 js第五章语句5.2 复合语句和空语句复合语句:用花括号将多条语句括起来,当一条语句使用123456789{ x = Math.PI; cx = Math.cos(x); console.log("cos(Pi)= " +cx);}//注意 1. 语句块结尾不需要分号 2. 语句 ... Read more »
链式前项星的概念与应用 Posted on 2020-04-21 | In bfs Words count in article: 1.2k | Reading time ≈ 5 链式前向星 链式前向星在存储图时十分有用,特别是当边有权值时。我们用过一道题目了来具体分析一下 链式前向星只是一种应用,是一种小技巧。所以我们先要构造一个链式前向星来存储数据。 1234567891011121314151617181920212223242526272829303132 ... Read more »
初识正则表达式 Posted on 2020-04-20 | In Regular Expression Words count in article: 2.9k | Reading time ≈ 11 正则表达式的探索与发现-爬虫项目系列博客 因为要实现爬虫的功能,正则表达式是必须要掌握和简单应用的。那么这对于从来没看到过正则表达式的小白来说,它无疑是头痛的,因为它的长这个样子 12var url_reg = /\/(\d{4})\/(\d{2})- ... Read more »
用nodejs来制作一个简单的爬虫来爬取网页信息 Posted on 2020-04-20 Words count in article: 4.9k | Reading time ≈ 18 用nodejs来制作一个简单的爬虫来爬取网页信息写在前面——知其然也要知其所以然 像我这样连冲个咖啡豆要记笔记的人,怎么能写自己都看不懂的博客呢?所以我的目标是你读完了我的博客,也可以写出爬虫来。 这一篇是目录性质的博客,冰冻三尺非一日之寒,爬虫项目只写一篇博客是完全不够的,所以我打算用分而治之的 ... Read more »