mirror of
https://github.com/TheAlgorithms/Java.git
synced 2026-03-13 08:40:43 +08:00
Fix package declarations (#2576)
This commit is contained in:
committed by
GitHub
parent
60a0c23544
commit
2b7a977cc8
@@ -2,9 +2,8 @@
|
||||
Time Complexity = O(E), where E is equal to the number of edges
|
||||
*/
|
||||
|
||||
package Graphs;
|
||||
package DataStructures.Graphs;
|
||||
|
||||
import java.lang.reflect.Array;
|
||||
import java.util.*;
|
||||
|
||||
public class A_Star {
|
||||
|
||||
@@ -4,9 +4,6 @@ for better understanding
|
||||
*/
|
||||
package DataStructures.Graphs;
|
||||
|
||||
import java.util.*;
|
||||
import java.io.*;
|
||||
|
||||
class dijkstras{
|
||||
|
||||
int k=9;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package Graphs;
|
||||
package DataStructures.Graphs;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Map;
|
||||
@@ -104,7 +104,6 @@ class TopologicalSort<E extends Comparable<E>>{
|
||||
*/
|
||||
ArrayList<E> topSortOrder(){
|
||||
calculateInDegree();
|
||||
int count = 0;
|
||||
Queue<E> q = new LinkedList<E>();
|
||||
|
||||
for(E vertex: inDegree.keySet()){
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
package DataStructures.Graphs;
|
||||
|
||||
// Problem -> Connect all the edges with the minimum cost.
|
||||
// Possible Solution -> Kruskal Algorithm (KA), KA finds the minimum-spanning-tree, which means, the
|
||||
// group of edges with the minimum sum of their weights that connect the whole graph.
|
||||
|
||||
Reference in New Issue
Block a user