Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
docs: add edge cases to JumpSearch documentation
  • Loading branch information
prashantpiyush1111 committed Apr 14, 2026
commit ca21a27946edb0ab5921af584d1b06803a307689
9 changes: 8 additions & 1 deletion src/main/java/com/thealgorithms/searches/JumpSearch.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,14 @@
*
* <p>
* <b>Space Complexity:</b> O(1) - only uses a constant amount of extra space
*
*
* <p>
* <b>Edge Cases:</b>
* <ul>
* <li>Empty array → returns -1</li>
* <li>Element not present → returns -1</li>
* <li>Single element array</li>
* </ul>
* <p>
* <b>Note:</b> Jump Search requires a sorted array. For unsorted arrays, use Linear Search.
* Compared to Linear Search (O(n)), Jump Search is faster for large arrays.
Expand Down
Loading