We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6cdf4df commit 39fd1a4Copy full SHA for 39fd1a4
level-1/숫자짝꿍&131128&.js
@@ -1,5 +1,9 @@
1
-// 정답 1 - ssi02014
2
-// 길이가 3,000,000 이므로 객체를 이용한 연산 횟수 최적화 풀이
+/**
+ * 풀이 - ssi02014
3
+ * X, Y의 길이가 굉장히 길어서 공통 숫자를 뽑아낼 때 객체를 이용해 연산 횟수 최적화
4
+ * X, Y를 배열로 변환 후에 배열 메서드를 사용해도 되지만, for of문보다 효율성 떨어짐
5
+ * (테스트 케이스 11 ~ 15 100ms~200ms 차이)
6
+ */
7
function solution(X, Y) {
8
const commons = [];
9
const obj = {};
0 commit comments