Skip to content

Refactor Dijkstra lazy: simplify, add docs and example#1301

Closed
williamfiset wants to merge 1 commit into
masterfrom
refactor-dijkstra
Closed

Refactor Dijkstra lazy: simplify, add docs and example#1301
williamfiset wants to merge 1 commit into
masterfrom
refactor-dijkstra

Conversation

@williamfiset

Copy link
Copy Markdown
Owner

Summary

  • Remove Edge and Node classes — use int[] for edges and double[] for PQ entries
  • Remove custom Comparator field, second constructor, and EPS epsilon comparison
  • Use Double.compare lambda for PQ ordering
  • Remove getGraph() and createEmptyGraph() helpers
  • Add Javadoc with time/space complexity, lazy approach description
  • Add main method with planar graph diagram
  • Make fields final, single-line bodies on new lines

Test plan

  • bazel build ...:graphtheory compiles successfully
  • bazel run ...:DijkstrasShortestPathAdjacencyList produces correct shortest paths
  • Add tests in follow-up

🤖 Generated with Claude Code

- Remove Edge/Node classes, use int[] and double[] arrays instead
- Remove custom Comparator field and EPS epsilon comparison
- Use Double.compare lambda for PQ ordering
- Add Javadoc with complexity, graph diagram, and main method
- Make fields final, single-line bodies on new lines

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@williamfiset williamfiset deleted the refactor-dijkstra branch April 3, 2026 22:50
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

Successfully merging this pull request may close these issues.

1 participant