-
Notifications
You must be signed in to change notification settings - Fork 12.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Array queue in js and ts #97
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 1 Ignored Deployment
|
Hashing search and test using go
|
||
/* 基于环形数组实现的队列 */ | ||
class ArrayQueue { | ||
queue; // 用于存储队列元素的数组 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use private member, #queue
class ArrayQueue { | ||
queue; // 用于存储队列元素的数组 | ||
front = 0; // 头指针,指向队首 | ||
rear = 0; // 尾指针,指向队尾 + 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as above
console.log("第 " + i + " 轮入队 + 出队后 queue = "); | ||
console.log(queue.toArray()); | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Redundant empty line.
Thanks for the contribution! This PR will keep open waiting for the By the way, could you help implement |
Add the TypeScript code and docs for Chapter of Sorting
List using Go
Update space_complexity.md
for coding and code translation
@krahets Hi, I have completed queue but I suddenly find that this title is Array queue and the branch is called array_queue. So should we still use this to merge the linkedlist_queue? |
Prefer to changing the title. |
It is easy to change the title for this PR. But the branch is also called array_queue, is it easy to rename a branch? |
I think it is not necessary. We can ignore this problem this time. |
This reverts commit 09f9c81.
It seems going wrong when cherry-picking my commits from another branch to this branch. |
Please close this PR and re-create one. |
This PR is closed because of the inconsistent header with the master branch of the main repo. It is recommended to
|
I used another branch and reraised a PR. |
Array queue in js and ts