Data Structure
TreeMap Heap PriorityQueue Insert() log(n) log(n) log(n) Delete() log(n) log(n) O(n) Pop() log(n) log(n) log(n) Find() log(n) log(n) Not support […]
TreeMap Heap PriorityQueue Insert() log(n) log(n) log(n) Delete() log(n) log(n) O(n) Pop() log(n) log(n) log(n) Find() log(n) log(n) Not support […]
什么题适合动态规划? 什么题不适合动态规划? 动规四要素 顺带回忆一下递归三要素 动态规划只能记录一种最优方案 练习题目: https://leetcode.com/problems/triangle/description https://leetcode.com/problems/minimum-path-sum/description https://leetcode.com/problems/unique-paths/description https://leetcode.com/problems/climbing-stairs/description https://leetcode.com/problems/longest-increasing-subsequence/description https://leetcode.com/problems/perfect-squares/description https://leetcode.com/problems/largest-divisible-subset/description https://leetcode.com/problems/russian-doll-envelopes/description https://leetcode.com/problems/frog-jump/description
什么是HTML? HTML: Hyper Text Markup Language. HTML tags HTML的标签分为两种:双标签(paired tag)和单标签(self-closing tag)。所谓的双标签,就是说该标签有一个起始标签(opening tag)和一个结束标签(closing tag),形式为:<起始标签>标签体</结束标签>。单标签的形式为:<标签名 />,其中foward slash是可以忽略不写的。 标签和标签之间的关系可以是并列,也可以是嵌套。如果是嵌套关系,编写代码的时候可以用tab键来进行缩进。 HTML的每个标签有其对应的标签属性(attribute),给标签提供一些附加信息。属性可以写在双标签中的起始标签里,或者单标签里。形式为: 有一些比较特殊的标签,只有属性名,没有属性值,例如: 注意事项: HTML的基本结构
为什么要学习React?换句话说,为什么原生js不够好呢? 虚拟DOM JSX语法规则 JS复习 组件 状态和展示 类中的方法this指向 现在的问题是当h1标签被click,调用回调函数changeWeather时,函数里的this为undefined,那该怎么办呢? 状态不可直接更改,需要调用setState({…})来更改,且更新是一种合并,不是替换。也就是说,同名的就替换了,不同名的保留。 如果不想写的这么麻烦,那可以用这种写法,完美解决this的问题 总结一下,state如果不依赖传参进来,直接写到class体内,然后方法也写成property的形式,并用箭头函数给其赋值。 对props进行限制: 组件的生命周期(旧版) 组件的生命周期(新版) 其实不管是新的生命周期还是旧的,常用的就3个: 三个废弃的钩子: 连续解构赋值加重命名:
NATURAL JOIN vs INNER JOIN 对比点 INNER JOIN NATURAL JOIN 是否需要指定连接条件 ✅ 需要使用 ON 明确指定连接字段 ❌ 不需要写 ON,自动匹配同名列 控制力 ✅
API key 放在请求头里,例如 Token(jwt) 先调用登录api来获得token 然后得到相应: 然后带上这个token在请求头里: OAuth2 1. 用户点击“用 Google 登录” 2. 前端拿到 Google 的 ID Token 3. 前端把
There’re different test types across software testing. Unit testing Unit testing means writting automated tests for the smallest testable parts
The original question can be found here. The question is asking to return all subsets of an integer array, and
The original question can be found here. The question is asking us to the minimum length of subarray that it’s