Merge pull request #1325 from mariaRoxana94/fix-error

Fixed 8XCorrectness_Bugs + 10XBad_Practice_Bugs + 14XDodgy_Code_Bugs
This commit is contained in:
Stepfen Shawn
2020-05-28 23:04:56 +08:00
committed by GitHub
25 changed files with 293 additions and 238 deletions

View File

@@ -23,7 +23,7 @@ start vertex, end vertes and weights. Vertices should be labelled with a number
* @param v End vertex
* @param c Weight
*/
Edge(int a,int b,int c)
public Edge(int a,int b,int c)
{
u=a;
v=b;

View File

@@ -127,8 +127,7 @@ class AdjacencyMatrixGraph {
* @return returns a string describing this graph
*/
public String toString() {
String s = new String();
s = " ";
String s = " ";
for (int i = 0; i < this.numberOfVertices(); i++) {
s = s + String.valueOf(i) + " ";
}