[algorithm] 문자열 붙여서 출력하기

인철·2024년 2월 25일
0

algorithm

목록 보기
61/91
post-thumbnail

두 개의 문자열 str1, str2가 공백으로 구분되어 입력으로 주어집니다. 입출력 예와 같이 str1과 str2을 이어서 출력하는 코드를 작성해 보세요.

public class Solution {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String a = sc.next();
        String b = sc.next();
        System.out.print(a + b);
    }
}
profile
같은글이있어도양해부탁드려요(킁킁)

0개의 댓글