Skip to content

Commit f38c7af

Browse files
fix: lint
1 parent c7800fe commit f38c7af

File tree

5 files changed

+12
-7
lines changed

5 files changed

+12
-7
lines changed

contains-duplicate/YoungSeok-Choi.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
import java.util.HashMap;
2+
import java.util.Map;
3+
14
class Solution {
25
// 시간복잡도 O(n)
36
public boolean containsDuplicate(int[] nums) {
@@ -13,4 +16,4 @@ public boolean containsDuplicate(int[] nums) {
1316

1417
return false;
1518
}
16-
}
19+
}

house-robber/YoungSeok-Choi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,4 +81,4 @@ public void dfs(int[] arr, int idx) {
8181
visit[idx] = false;
8282
curSum -= arr[idx];
8383
}
84-
}
84+
}

longest-consecutive-sequence/YoungSeok-Choi.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import java.util.Arrays;
2-
import java.util.*;
32

43
class Solution {
54
public int longestConsecutive(int[] nums) {
@@ -32,4 +31,4 @@ public int longestConsecutive(int[] nums) {
3231

3332
return Math.max(maxSeq, curSeq);
3433
}
35-
}
34+
}

product-of-array-except-self/YoungSeok-Choi.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ public int[] productExceptSelf(int[] nums) {
4444

4545
return result;
4646
}
47-
}
47+
}

two-sum/YoungSeok-Choi.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
// time complexity: O(n);
2-
32
// 특정 nums[i] 가 target이 되기위한 보수 (target - nums[i])를 candidate Map에서 찾으면 종료
3+
4+
import java.util.HashMap;
5+
import java.util.Map;
6+
47
class Solution {
58
public int[] twoSum(int[] nums, int target) {
69
Map<Integer, Integer> candidate = new HashMap<>();
@@ -17,4 +20,4 @@ public int[] twoSum(int[] nums, int target) {
1720
}
1821
return new int[0];
1922
}
20-
}
23+
}

0 commit comments

Comments
 (0)