Skip to content

Commit 0d87b63

Browse files
committed
Fixed sonar
1 parent 8bde88b commit 0d87b63

File tree

2 files changed

+2
-2
lines changed
  • src/main/kotlin/g3301_3400

2 files changed

+2
-2
lines changed

src/main/kotlin/g3301_3400/s3376_minimum_time_to_break_locks_i/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class Solution {
3434
while (nums[j] <= nums[i]) {
3535
j--
3636
}
37-
nums[i] = nums.set(j, nums[i])
37+
nums[j] = nums[i]
3838
nums.subList(i + 1, nums.size).reverse()
3939
return true
4040
}

src/main/kotlin/g3301_3400/s3377_digit_operations_to_make_two_integers_equal/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ class Solution {
2929
val pq = PriorityQueue<IntArray>(Comparator { a: IntArray, b: IntArray -> a[0] - b[0] })
3030
visited[n] = true
3131
pq.add(intArrayOf(n, n))
32-
while (!pq.isEmpty()) {
32+
while (pq.isNotEmpty()) {
3333
val current = pq.poll()
3434
val cost = current[0]
3535
val num = current[1]

0 commit comments

Comments
 (0)