Skip to content

Commit 851cb82

Browse files
committed
refactor: remove redundant comments in Bellman-Ford search implementation
1 parent 88e7a6e commit 851cb82

File tree

3 files changed

+0
-2
lines changed

3 files changed

+0
-2
lines changed
File renamed without changes.

algorithms/search/bellman-ford-search/bellmanFordSearch.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,8 @@ export class BellmanFord {
1616
* @throws {Error} If the input parameters are invalid.
1717
*/
1818
static findShortestPaths(vertices: number, edges: Edge[], source: number): number[] | null {
19-
// Validate input
2019
this.validateInput(vertices, edges, source);
2120

22-
// Initialize distances
2321
const distances = new Array(vertices).fill(Infinity);
2422
distances[source] = 0;
2523

0 commit comments

Comments
 (0)