프로그래머스 181857 자바

    [프로그래머스, 181857] 배열의 길이를 2의 거듭제곱으로 만들기 (java)

    https://school.programmers.co.kr/learn/courses/30/lessons/181857 프로그래머스SW개발자를 위한 평가, 교육, 채용까지 Total Solution을 제공하는 개발자 성장을 위한 베이스캠프programmers.co.kr메모리: 89.5 MB, 시간: 0.05 ms사용 알고리즘: 구현class Solution { public int[] solution(int[] arr) { // 배열 길이 구하기 int length = 1; while(arr.length > length) length *= 2; int[] answer = new int[length]; ..