
js
小句
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
RegExp练习
https://www.liaoxuefeng.com/wiki/1022910821149312/1023021582119488 'use strict'; var re = /^\<([\s\w]+)\>\s(\w+\@\w+\.(com|org))$/; // var re = /^\<([\s\w]+)\>\s(\w+\@\w+\.org|com)$/; console.log(re.test('<Tom Paris> [email protected]')原创 2022-01-08 18:55:01 · 324 阅读 · 0 评论 -
js-generator(生成器)
'use strict' function* fib(max) { var a = 0, b = 1, n = 0; while (n < max) { console.log(".........1........."); yield a; console.log(".........2........."); [a, b] = [b, a + b]; c原创 2022-01-07 16:23:28 · 484 阅读 · 0 评论