127. n 번째 원소부터

김해준's avatar
Dec 24, 2025
127. n 번째 원소부터

사용언어 : Java

문제
notion image
풀이
class Solution { public int[] solution(int[] num_list, int n) { int length = num_list.length - n; int[] answer = new int[length + 1]; for(int i = 0 ;i < length + 1 ; i++) { answer[i] = num_list[n - 1 + i]; } return answer; } }
notion image
Share article