Repository for gitalk of my blog.
321paranoiawhy / gitalk Goto Github PK
View Code? Open in Web Editor NEWRepository for gitalk of my blog.
Repository for gitalk of my blog.
https://321paranoiawhy.github.io/post/JavaScript%E6%95%B0%E7%BB%84%E8%BF%9E%E7%BB%ADn%E9%A1%B9%E7%9A%84%E6%9C%80%E5%A4%A7%E5%92%8C
// 求数组连续 n 项的最大和 function nNumbersMaxSum(array, n) { // 假值处理 // 第一种方式, 虽然去除了假值, 但其位置也被删除了, 新数组长度有所变化 let...
https://321paranoiawhy.github.io/post/data-xx%E5%B1%9E%E6%80%A7%E4%B8%8Eattr%E5%87%BD%E6%95%B0
HTML 元素的 data-xx 属性<!-- HTML --> <p data-text='123456'>Paragraph</p> 获取 HTML 元素的 data-xx 属性在 CSS 中可通过 a...
https://321paranoiawhy.github.io/post/LeetCode-%E5%89%91%E6%8C%87Offer-15-%E4%BA%8C%E8%BF%9B%E5%88%B6%E4%B8%AD1%E7%9A%84%E4%B8%AA%E6%95%B0
题目描述本题同 LeetCode-191-位1的个数。 编写一个函数,输入是一个无符号整数(以二进制串的形式),返回其二进制表达式中数字位数为 ‘1’ 的个数(也被称为 Hamming weight )。 示例1 输入:n = 11 (控制台输入 0000000000...
https://321paranoiawhy.github.io/post/Garbage-Collection
node 手动触发 gc# 显示 v8 选项 node --v8-options node --expose-gc # 查看全局对象 global 或 globalThis global # globalThis (global === global...
https://321paranoiawhy.github.io/post/%E6%B5%85%E6%9E%90JavaScript%E4%BC%AA%E9%9A%8F%E6%9C%BA%E6%95%B0
Math.random()ECMAScript 21.3.2.27 Math.random (): 提示 Returns a Number value with positive sign, greater than or equal to +0 but strictly les...
https://321paranoiawhy.github.io/post/Using-SVG-in-CSS-background-image
background-imagebackground-image 的值可以是 none 或者 一个合法的 <image> 值。 /* 1. network image */ div { background-image: url(http...
https://321paranoiawhy.github.io/post/Import-JSON-File
import assertionsstatic importSee Here 从本地引入 test.json: import test from './test.json' assert {type: 'json'}...
https://321paranoiawhy.github.io/post/git-rename-folder
how to rename a folder using git mv# rename old folder to olds folder git mv old olds # rename olds folder to new folder git mv olds new # ...
https://321paranoiawhy.github.io/post/Google-Firebase%E5%88%86%E5%89%B2%E7%BA%BF%E4%B9%8BCSS%E5%AE%9E%E7%8E%B0
原效果Google-Firebase 单一的分割线之 CSS 实现利用 span 标签, 通过设定 display: inline-block; , 并设置其宽度为 1px, 高度为 30px, 即可实现分割线。 <span class="fireba...
https://321paranoiawhy.github.io/post/%E6%B5%85%E6%9E%90JavaScript-console/
consoleconsole 是 一个 JavaScript 对象, 可以用来输出信息到控制台。不同的浏览器会各自实现 console。 typeof console; // "object" 提示 WHATWG Chrome - Devt...
https://321paranoiawhy.github.io/post/Web-Components-Part-2
shadow DOM 内设置内部元素样式Reference: How to create a style tag using JavaScript? - GeeksforGeeks Web Components中引入外部CSS的3种方法 - 张鑫旭 Shadow DOM sty...
https://321paranoiawhy.github.io/post/%E7%B2%BE%E5%87%86%E8%A6%86%E7%9B%96%E9%97%AE%E9%A2%98
精确覆盖问题Exact cover wiki Dancing Links OI Wiki A Sudoku Solver in Java implementing Knuth’s Dancing Links Algorithm 数独规则回顾 每个格子只能填入 1 ~ 9 中的一个...
https://321paranoiawhy.github.io/post/JavaScript%E6%95%B0%E7%BB%84%E4%B9%8B%E5%A5%87%E6%8A%80%E6%B7%AB%E5%B7%A7/
快速创建有规律数组 元素为 0 ~ 99 的数组// new Array(100) 创建一个长度为 100 的空数组 (new 关键字可省略) // keys() 返回数组索引的一个迭代器 // Array.from(...
https://321paranoiawhy.github.io/post/MDN-TOC%E4%B9%8BCSS%E5%AE%9E%E7%8E%B0
原效果MDN-JavaScript 完整实现<section> <h2>In this article</h2> <ul> <li><a href="">学习路线&l...
https://321paranoiawhy.github.io/post/LeetCpde-258-Add-Digits
题目描述给定一个非负整数 num,反复将各个位上的数字相加,直到结果为一位数。返回这个结果。 示例1: 输入: num = 38输出: 2解释: 各位相加的过程为:38 –> 3 + 8 –> 1111 –> 1 + 1 –> 2由于 2 是一...
https://321paranoiawhy.github.io/post/Web-Components-Part-1
生命周期函数Creating Web Components — Lifecycle Callbacks - Medium connectedCallback()当 web components 首次被挂载到 DOM 上, connectedCallback() 回调函数将被执行...
https://321paranoiawhy.github.io/post/gitignore
创建 .gitignore 文件在文件夹根目录下手动创建 .gitignore 文件即可。 添加忽略文件# 忽略 test.txt 文件 test.txt # 忽略所有 txt 文件 *.txt # 忽略 .gitignore 文件 .gitignore 添加忽略文件夹# 忽略...
https://321paranoiawhy.github.io/post/AbstractAndStrictEqualityComparison
x === 1 && x === 2 && x === 3let x = 1; console.log(x === 1 && x === 2 &&...
https://321paranoiawhy.github.io/post/%E6%95%B0%E7%8B%AC%E6%B8%B8%E6%88%8F%E8%AE%BE%E8%AE%A1%E4%B8%8E%E5%AE%9E%E7%8E%B0
数独简介数独起源数独分类 河图洛书 射雕英雄传 那女子沮丧失色, 身子摇了几摇, 突然一交跌在细沙之中, 双手...
https://321paranoiawhy.github.io/post/LeetCode-796-Rotate-String/?code=f733228a41a852bec782
题目描述LeetCode-796-Rotate-String Given two strings s and goal, return true if and only if s can become goal after some number of shifts on s....
https://321paranoiawhy.github.io/post/JavaScript%E7%B1%BB%E5%9E%8B%E6%A0%A1%E9%AA%8C%E5%87%BD%E6%95%B0%E5%B0%81%E8%A3%85
类型校验函数的封装// JavaScript 类型校验 checkType 函数, 返回值为字符串类型 function typeCheck(value) { // 1. null // typeof() 方法...
https://321paranoiawhy.github.io/post/%E6%B7%B1%E5%85%A5%E8%A7%A3%E6%9E%90%E4%BD%8D%E8%BF%90%E7%AE%97%E6%80%A7%E8%B4%A8
二进制回顾十进制整数转换为二进制十进制整数转换为二进制可采用 除2取余, 逆序排列 (短除法) : $$\begin{table}[]\begin{tabular}{ccccccc}\multicolumn{1}{c|}{2} & 8 & & &...
https://321paranoiawhy.github.io/post/LeetCode-415-Add-Strings
题目描述给定两个字符串形式的非负整数 num1 和 num2 ,计算它们的和并同样以字符串形式返回。 你不能使用任何內建的用于处理大整数的库(比如 BigInteger), 也不能直接将输入的字符串转换为整数形式。 示例 1: 输入:num1 = “11”, num2...
https://321paranoiawhy.github.io/post/LeetCode-53-Maximum-Subarray
// LeetCode-53 https://leetcode.cn/problems/maximum-subarray/ // 剑指Offer-42 https://...
https://321paranoiawhy.github.io/post/CSS-Variable
定义和使用 CSS 变量CSS 变量可以全局定义, 即在 :root 伪类选择器中按如下定义: :root { /* 1. 必须以 -- 开头 / / 2. 区分大小写, 即 --main-color 和 --Main-Color 为完...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.