Add FindMiddleOfSinglyLinkedList algorithm and tests#6617
Closed
Hirannya-Mhaisbadwe wants to merge 1 commit intoTheAlgorithms:masterfrom
Closed
Add FindMiddleOfSinglyLinkedList algorithm and tests#6617Hirannya-Mhaisbadwe wants to merge 1 commit intoTheAlgorithms:masterfrom
Hirannya-Mhaisbadwe wants to merge 1 commit intoTheAlgorithms:masterfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #6617 +/- ##
============================================
+ Coverage 75.68% 75.70% +0.02%
- Complexity 5754 5755 +1
============================================
Files 699 699
Lines 19725 19725
Branches 3826 3826
============================================
+ Hits 14929 14933 +4
+ Misses 4216 4214 -2
+ Partials 580 578 -2 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Author
|
Under Hacktober25 |
Member
|
Closed due to empty files. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
clang-format -i --style=file path/to/your/file.javaThis PR adds an algorithm to find the middle of a singly linked list, along with unit tests.
Changes include:
FindMiddleOfSinglyLinkedList.java— implements slow/fast pointer technique to find the middle.FindMiddleOfSinglyLinkedListTest.java— JUnit tests covering odd/even lists, single-node, two-node, empty list, and longer lists.Motivation:
Fixes #6615