Skip to content

Commit 8bc5622

Browse files
committed
Fixed sonar
1 parent 7e032ac commit 8bc5622

File tree

1 file changed

+1
-1
lines changed
  • src/main/java/g3501_3600/s3559_number_of_ways_to_assign_edge_weights_ii

1 file changed

+1
-1
lines changed

src/main/java/g3501_3600/s3559_number_of_ways_to_assign_edge_weights_ii/Solution.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public int[] assignEdgeWeights(int[][] edges, int[][] queries) {
6767
adj.get(i[0] - 1).add(i[1] - 1);
6868
adj.get(i[1] - 1).add(i[0] - 1);
6969
}
70-
int m = (int) (Math.ceil(Math.log(n - 1) / Math.log(2))) + 1;
70+
int m = (int) (Math.ceil(Math.log(n - 1.0) / Math.log(2))) + 1;
7171
jumps = new int[n][m];
7272
mark(0, -1);
7373
for (int j = 1; j < m; j++) {

0 commit comments

Comments
 (0)