Skip to content

Commit ce5bac4

Browse files
committed
[level 0] Title: 대문자와 소문자, Time: 0.58 ms, Memory: 78.5 MB -BaekjoonHub
1 parent 9662bdb commit ce5bac4

2 files changed

Lines changed: 16 additions & 3 deletions

File tree

프로그래머스/0/120893. 대문자와 소문자/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# [level 0] 대문자와 소문자 - 120893
22

3-
[문제 링크](https://school.programmers.co.kr/learn/courses/30/lessons/120893)
3+
[문제 링크](https://school.programmers.co.kr/learn/courses/30/lessons/120893?language=java)
44

55
### 성능 요약
66

7-
메모리: 10.1 MB, 시간: 0.15 ms
7+
메모리: 78.5 MB, 시간: 0.58 ms
88

99
### 구분
1010

@@ -16,7 +16,7 @@
1616

1717
### 제출 일자
1818

19-
2024년 05월 25일 12:17:38
19+
2026년 06월 23일 08:58:33
2020

2121
### 문제 설명
2222

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
class Solution {
2+
public String solution(String my_string) {
3+
StringBuilder sb = new StringBuilder();
4+
5+
for (int i = 0; i < my_string.length(); i++) {
6+
char c = my_string.charAt(i);
7+
8+
if (Character.isUpperCase(c)) sb.append(Character.toLowerCase(c));
9+
else sb.append(Character.toUpperCase(c));
10+
}
11+
return sb.toString();
12+
}
13+
}

0 commit comments

Comments
 (0)