Skip to content
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

data-structures bugs #6

Open
tomcostello opened this issue Jul 4, 2019 · 0 comments
Open

data-structures bugs #6

tomcostello opened this issue Jul 4, 2019 · 0 comments

Comments

@tomcostello
Copy link

In Queue.js peek returns the last element added, not the earliest still in the queue.

In the test for Queue.js the contents are listed backwards in the test, so after enqueueing 1 and 2, the contents should be 2,1 not 1,2.

In Stack.js, the tests expect, and solution code returns undefined for peek on an empty stack rather than null.

In LinkedList.js tail is not set correctly in InsertAfter.

In LinkedList the ReadMe says "The delete method removes the first node with the specified value." but the code deletes all nodes with the given value.

tomcostello added a commit to tomcostello/algorithms that referenced this issue Jul 4, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant