diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index f33a72b19..cb6529704 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -1,5 +1,5 @@ If this PR is related to coding or code translation, please fill out the checklist and paste the console outputs to the PR. -- [ ] I've tested the code and ensured the outputs are the same as the outputs of reference codes. -- [ ] I've checked the codes (formatting, comments, indentation, file header, etc) carefully. +- [ ] I've tested the code and ensured the outputs are the same as the outputs of reference code. +- [ ] I've checked the code (formatting, comments, indentation, file header, etc) carefully. - [ ] The code does not rely on a particular environment or IDE and can be executed on a standard system (Win, macOS, Ubuntu). diff --git a/codes/javascript/chapter_array_and_linkedlist/array.js b/codes/javascript/chapter_array_and_linkedlist/array.js index 0c8343250..a6ce0b53e 100644 --- a/codes/javascript/chapter_array_and_linkedlist/array.js +++ b/codes/javascript/chapter_array_and_linkedlist/array.js @@ -66,7 +66,7 @@ function find(nums, target) { return -1; } -/* Driver Codes*/ +/* Driver Code */ /* 初始化数组 */ const arr = new Array(5).fill(0); console.log('数组 arr =', arr); diff --git a/codes/javascript/chapter_hashing/hash_map_open_addressing.js b/codes/javascript/chapter_hashing/hash_map_open_addressing.js index 9d03a84d5..b03b6744d 100644 --- a/codes/javascript/chapter_hashing/hash_map_open_addressing.js +++ b/codes/javascript/chapter_hashing/hash_map_open_addressing.js @@ -53,7 +53,7 @@ class HashMapOpenAddressing { // 若遇到指定 key ,则返回对应 val if ( this.#buckets[j].key === key && - this.#buckets[j][key] !== this.#removed.key + this.#buckets[j].key !== this.#removed.key ) return this.#buckets[j].val; } @@ -74,7 +74,7 @@ class HashMapOpenAddressing { // 若遇到空桶、或带有删除标记的桶,则将键值对放入该桶 if ( this.#buckets[j] === null || - this.#buckets[j][key] === this.#removed.key + this.#buckets[j].key === this.#removed.key ) { this.#buckets[j] = new Pair(key, val); this.#size += 1; diff --git a/codes/python/modules/__init__.py b/codes/python/modules/__init__.py index 28175051e..0ff746b7d 100644 --- a/codes/python/modules/__init__.py +++ b/codes/python/modules/__init__.py @@ -2,7 +2,7 @@ # https://peps.python.org/pep-0585/ from __future__ import annotations -# Import common libs here to simplify the codes by `from module import *` +# Import common libs here to simplify the code by `from module import *` from .list_node import ( ListNode, list_to_linked_list, diff --git a/codes/typescript/chapter_hashing/hash_map_open_addressing.ts b/codes/typescript/chapter_hashing/hash_map_open_addressing.ts index adca37ce1..40fe5552b 100644 --- a/codes/typescript/chapter_hashing/hash_map_open_addressing.ts +++ b/codes/typescript/chapter_hashing/hash_map_open_addressing.ts @@ -55,7 +55,7 @@ class HashMapOpenAddressing { // 若遇到指定 key ,则返回对应 val if ( this.#buckets[j].key === key && - this.#buckets[j][key] !== this.#removed.key + this.#buckets[j].key !== this.#removed.key ) return this.#buckets[j].val; } @@ -76,7 +76,7 @@ class HashMapOpenAddressing { // 若遇到空桶、或带有删除标记的桶,则将键值对放入该桶 if ( this.#buckets[j] === null || - this.#buckets[j][key] === this.#removed.key + this.#buckets[j].key === this.#removed.key ) { this.#buckets[j] = new Pair(key, val); this.#size += 1; diff --git a/docs/index.md b/docs/index.md index 0e040d068..14d8b9cd3 100644 --- a/docs/index.md +++ b/docs/index.md @@ -22,7 +22,7 @@ hide:   - GitHub contributors + GitHub contributors