프로그래머스/Lv.1 [Swift] 바탕화면 정리 - import Foundation func solution(_ wallpaper:[String]) -> [Int] { var lux = 51, luy = 51, rdx = -1, rdy = -1 for (i, str) in wallpaper.enumerated() { for (j, file) in str.enumerated() { if file == "#" { lux = min(lux, i) luy = min(luy, j) rdx = max(rdx, i) rdy = max(rdy, j) } } } return [lux, luy, rdx + 1, rdy + 1] } 공유하기 게시글 관리 구독하기iOS 개발 공부 저작자표시 '프로그래머스 > Lv.1' 카테고리의 다른 글 [Swift] 공원 산책 (0) 2023.04.25 [Swift] 달리기 경주 (0) 2023.04.25 [Swift] 덧칠하기 (0) 2023.04.15 [Swift] 카드뭉치 (0) 2023.04.14 [Swift] 추억점수 (0) 2023.04.14 Contents 당신이 좋아할만한 콘텐츠 [Swift] 공원 산책 2023.04.25 [Swift] 달리기 경주 2023.04.25 [Swift] 덧칠하기 2023.04.15 [Swift] 카드뭉치 2023.04.14 댓글 0 + 이전 댓글 더보기