Home [1일 1문제] 3월 13일 문제풀이
Post
Cancel

[1일 1문제] 3월 13일 문제풀이

✏️백준 10871번 : X보다 작은 수

문제

나의 풀이

1
2
3
4
5
6
7
8
let nx = readLine()!.split(separator: " ").map{ Int(String($0))! }
let nums = readLine()!.split(separator: " ").map{ Int(String($0))! }

for n in nums {
    if n < nx[1] {
        print(n, terminator: " ")
    }
}

(추가예정)

공식문서 살펴보기📚

- print(_:separator:terminator:)

This post is licensed under CC BY 4.0 by the author.