프로그래머스 - LV.0 - 카운트 업

박종일·2023년 8월 5일
0

프로그래머스 LV.0

목록 보기
26/46

나의 풀이

def solution(start, end):
    answer = []
    for i in range(start,end+1):
        answer.append(i)
    return answer

다른 풀이

def solution(start, end):
    return list(range(start, end + 1))

간단한 for문의 인수가 어떻게 들어가는 지 확인!
기본적인 문제!

profile
존경하는 인물: 스토브리그 백승수 단장(남궁민)

0개의 댓글