[Java] 특정 문자 뒤집기 - String(문자열)
·
💡 Algorithm/인프런
Problem 💻영어 알파벳과 특수문자로 구성된 문자열이 주어지면 영어 알파벳만 뒤집고,특수문자는 자기 자리에 그대로 있는 문자열을 만들어 출력하는 프로그램을 작성하세요. Solution 💡public class INF0105 { public static void main(String[] args) { Scanner sc = new Scanner(System.in); String s = sc.next(); INF0105 inf = new INF0105(); System.out.println(inf.solution(s)); } public String solution(String s) { String answer = ""; ..