結果

問題 No.1469 programing
ユーザー face4face4
提出日時 2021-04-10 12:49:34
言語 Kotlin
(1.9.23)
結果
AC  
実行時間 687 ms / 3,000 ms
コード長 213 bytes
コンパイル時間 15,436 ms
コンパイル使用メモリ 417,140 KB
実行使用メモリ 74,132 KB
最終ジャッジ日時 2023-09-08 08:59:28
合計ジャッジ時間 21,379 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 287 ms
52,300 KB
testcase_01 AC 287 ms
52,456 KB
testcase_02 AC 295 ms
52,604 KB
testcase_03 AC 293 ms
52,236 KB
testcase_04 AC 296 ms
52,216 KB
testcase_05 AC 302 ms
52,404 KB
testcase_06 AC 296 ms
52,400 KB
testcase_07 AC 299 ms
52,480 KB
testcase_08 AC 416 ms
54,344 KB
testcase_09 AC 416 ms
54,308 KB
testcase_10 AC 417 ms
54,676 KB
testcase_11 AC 430 ms
56,496 KB
testcase_12 AC 429 ms
56,696 KB
testcase_13 AC 269 ms
50,244 KB
testcase_14 AC 440 ms
56,972 KB
testcase_15 AC 447 ms
57,016 KB
testcase_16 AC 447 ms
57,116 KB
testcase_17 AC 687 ms
74,132 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

fun main() {
    val s = readLine()!!.toCharArray()
    val sb = StringBuilder()
    sb.append(s[0])
    for(i in 1 until s.size){
        if(sb.last() != s[i])   sb.append(s[i])
    }
    println(sb.toString())
}
0