숨어있는 숫자의 덧셈1 [프로그래머스] Lv.0 숨어있는 숫자의 덧셈 (1) - 자바(java) 문제 설명 문자열 my_string이 매개변수로 주어집니다. my_string안의 모든 자연수들의 합을 return하도록 solution 함수를 완성해주세요. 내가 작성한 답 class Solution { public int solution(String my_string) { int answer = 0; my_string = my_string.replaceAll("[^0-9]", ""); String[] str = my_string.split(""); for(int i=0; i 2023. 10. 8. 이전 1 다음