Skip to content

Commit 24561a7

Browse files
committed
점위 위치 구하기(기초)
1 parent cee4b18 commit 24561a7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

unn04012/queue/Number_of_pairs.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
function solution(n) {
2+
const divisors = [];
3+
4+
for (let i = 1; i <= n; i++) if (n % i === 0) divisors.push(i);
5+
return divisors.length;
6+
}
7+
8+
console.log(solution(100));

0 commit comments

Comments
 (0)