[백준/코틀린] 4153번: 직각삼각형
브론즈 3
링크
풀이
생략
코드
1
2
3
4
5
6
7
8
9
10
11
12
13
fun main() {
while (true) {
val (a, b, c) = readln().split(" ").map { it.toInt() }
.also { if (it[0] == 0) return }
.sorted()
println(
if (a * a + b * b == c * c) "right"
else "wrong"
)
}
}
This post is licensed under CC BY 4.0 by the author.