Title: 字节:输出以下代码运行结果,为什么?如果希望每隔 1s 输出一个结果,应该如何改造?注意不可改动 square 方法 · Issue #69 · sisterAn/JavaScript-Algorithms · GitHub
Open Graph Title: 字节:输出以下代码运行结果,为什么?如果希望每隔 1s 输出一个结果,应该如何改造?注意不可改动 square 方法 · Issue #69 · sisterAn/JavaScript-Algorithms
X Title: 字节:输出以下代码运行结果,为什么?如果希望每隔 1s 输出一个结果,应该如何改造?注意不可改动 square 方法 · Issue #69 · sisterAn/JavaScript-Algorithms
Description: const list = [1, 2, 3] const square = num => { return new Promise((resolve, reject) => { setTimeout(() => { resolve(num * num) }, 1000) }) } function test() { list.forEach(async x=> { const res = await square(x) console.log(res) }) } test()
Open Graph Description: const list = [1, 2, 3] const square = num => { return new Promise((resolve, reject) => { setTimeout(() => { resolve(num * num) }, 1000) }) } function test() { list.forEach(async x=> { const res = a...
X Description: const list = [1, 2, 3] const square = num => { return new Promise((resolve, reject) => { setTimeout(() => { resolve(num * num) }, 1000) }) } function test() { list.forEach(async x=> { c...
Opengraph URL: https://github.com/sisterAn/JavaScript-Algorithms/issues/69
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"字节:输出以下代码运行结果,为什么?如果希望每隔 1s 输出一个结果,应该如何改造?注意不可改动 square 方法","articleBody":"```js\r\nconst list = [1, 2, 3]\r\nconst square = num =\u003e {\r\n return new Promise((resolve, reject) =\u003e {\r\n setTimeout(() =\u003e {\r\n resolve(num * num)\r\n }, 1000)\r\n })\r\n}\r\n\r\nfunction test() {\r\n list.forEach(async x=\u003e {\r\n const res = await square(x)\r\n console.log(res)\r\n })\r\n}\r\ntest()\r\n```","author":{"url":"https://github.com/sisterAn","@type":"Person","name":"sisterAn"},"datePublished":"2020-06-21T15:45:41.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":5},"url":"https://github.com/69/JavaScript-Algorithms/issues/69"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:e32fb53a-5460-7b77-fc43-a85ca7ed0aaa |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | DE28:7D80C:C1026:10C58F:696A6876 |
| html-safe-nonce | 4012bb3063efbb84f0c0ce4ece89cb9e0abb049e729985e6a30d299cd7d55b73 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJERTI4OjdEODBDOkMxMDI2OjEwQzU4Rjo2OTZBNjg3NiIsInZpc2l0b3JfaWQiOiIxNjM1MDcwNzg4NTUwMjY4MDYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 0757b4cf199fdbeb17154c091af4494804bcc12ee17895a3587d70e6b7dc6999 |
| hovercard-subject-tag | issue:642587596 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/sisterAn/JavaScript-Algorithms/69/issue_layout |
| twitter:image | https://opengraph.githubassets.com/bd026add22244986130264012b50bdfc8f68d46a6bfb10a6cc1778e4e08abe1e/sisterAn/JavaScript-Algorithms/issues/69 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/bd026add22244986130264012b50bdfc8f68d46a6bfb10a6cc1778e4e08abe1e/sisterAn/JavaScript-Algorithms/issues/69 |
| og:image:alt | const list = [1, 2, 3] const square = num => { return new Promise((resolve, reject) => { setTimeout(() => { resolve(num * num) }, 1000) }) } function test() { list.forEach(async x=> { const res = a... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | sisterAn |
| hostname | github.com |
| expected-hostname | github.com |
| None | 6fea32d5b7276b841b7a803796d9715bc6cfb31ed549fdf9de2948ac25d12ba6 |
| turbo-cache-control | no-preview |
| go-import | github.com/sisterAn/JavaScript-Algorithms git https://github.com/sisterAn/JavaScript-Algorithms.git |
| octolytics-dimension-user_id | 19721451 |
| octolytics-dimension-user_login | sisterAn |
| octolytics-dimension-repository_id | 252061924 |
| octolytics-dimension-repository_nwo | sisterAn/JavaScript-Algorithms |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 252061924 |
| octolytics-dimension-repository_network_root_nwo | sisterAn/JavaScript-Algorithms |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f2d9f6432a5a115ec709295ae70623f33bb80aee |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width