Skip to content

Commit 432ef48

Browse files
committed
[level 1] Title: 나누어 떨어지는 숫자 배열, Time: 1.71 ms, Memory: 14.9 MB -BaekjoonHub
1 parent 2ea6926 commit 432ef48

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

프로그래머스/1/12910. 나누어 떨어지는 숫자 배열/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
### 성능 요약
66

7-
메모리: 10.1 MB, 시간: 0.03 ms
7+
메모리: 14.9 MB, 시간: 1.71 ms
88

99
### 구분
1010

@@ -16,7 +16,7 @@
1616

1717
### 제출 일자
1818

19-
2024년 06월 26일 11:15:43
19+
2026년 07월 14일 12:05:55
2020

2121
### 문제 설명
2222

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
def solution(arr, divisor):
22
ans = []
3-
for i in arr:
4-
if i % divisor == 0:
5-
ans.append(i)
3+
for num in arr:
4+
if num % divisor == 0:
5+
ans.append(num)
66
if len(ans) == 0:
7-
ans.append(-1)
7+
return [-1]
88
return sorted(ans)

0 commit comments

Comments
 (0)