結果

問題 No.668 6.0*10^23
ユーザー 💕💖💞💕💖💞
提出日時 2018-06-06 22:48:41
言語 Kotlin
(1.9.23)
結果
WA  
実行時間 -
コード長 544 bytes
コンパイル時間 10,241 ms
コンパイル使用メモリ 434,732 KB
実行使用メモリ 65,720 KB
最終ジャッジ日時 2024-04-30 18:43:25
合計ジャッジ時間 29,441 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 265 ms
56,928 KB
testcase_01 WA -
testcase_02 AC 363 ms
61,460 KB
testcase_03 AC 346 ms
59,352 KB
testcase_04 AC 354 ms
59,356 KB
testcase_05 AC 341 ms
59,276 KB
testcase_06 AC 359 ms
59,320 KB
testcase_07 AC 281 ms
56,788 KB
testcase_08 AC 270 ms
56,808 KB
testcase_09 AC 268 ms
56,820 KB
testcase_10 AC 351 ms
59,356 KB
testcase_11 WA -
testcase_12 AC 333 ms
59,384 KB
testcase_13 AC 379 ms
63,432 KB
testcase_14 AC 370 ms
63,576 KB
testcase_15 AC 321 ms
57,240 KB
testcase_16 AC 333 ms
59,344 KB
testcase_17 AC 379 ms
63,664 KB
testcase_18 AC 362 ms
61,552 KB
testcase_19 AC 354 ms
59,244 KB
testcase_20 AC 362 ms
61,432 KB
testcase_21 AC 373 ms
61,376 KB
testcase_22 AC 376 ms
63,624 KB
testcase_23 AC 364 ms
61,456 KB
testcase_24 AC 328 ms
57,116 KB
testcase_25 AC 377 ms
63,644 KB
testcase_26 AC 288 ms
57,036 KB
testcase_27 AC 369 ms
61,444 KB
testcase_28 AC 376 ms
63,560 KB
testcase_29 AC 351 ms
59,344 KB
testcase_30 AC 370 ms
63,564 KB
testcase_31 AC 354 ms
61,324 KB
testcase_32 AC 316 ms
57,280 KB
testcase_33 AC 364 ms
63,636 KB
testcase_34 AC 342 ms
59,356 KB
testcase_35 AC 342 ms
59,376 KB
testcase_36 AC 366 ms
61,508 KB
testcase_37 AC 384 ms
63,596 KB
testcase_38 AC 362 ms
61,564 KB
testcase_39 WA -
testcase_40 AC 385 ms
63,524 KB
testcase_41 AC 367 ms
63,628 KB
testcase_42 AC 350 ms
59,316 KB
testcase_43 AC 377 ms
63,628 KB
testcase_44 AC 376 ms
65,712 KB
testcase_45 AC 268 ms
57,016 KB
testcase_46 AC 263 ms
56,848 KB
testcase_47 AC 261 ms
56,848 KB
testcase_48 AC 264 ms
56,856 KB
testcase_49 AC 267 ms
56,856 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.kt:1:10: warning: parameter 'args' is never used
fun main(args:Array<String>) {
         ^
Main.kt:4:7: warning: variable 'buff' is never used
  val buff = mutableListOf<Int>()
      ^

ソースコード

diff #

fun main(args:Array<String>) {
  val input = readLine()!!.toList().map { it.toString().toInt() }.reversed().toMutableList()

  val buff = mutableListOf<Int>()
  // round op
  for( c in (0..input.size-1-1-1) ) {
    if( input[c] >= 5 ) input[c+1] += 1
  }
  if( input[input.size-2] >= 10 ) {
    input[input.size-2] = 0
    input[input.size-1] += 1
  }
  if( input[input.size-1] >= 10 ) {
    input[input.size-1] = 0
    input.add( 1 )
  }
  val r = input.reversed()
  val h1 = r[0]
  val h2 = r[1]

  println("${h1}.${h2}*10^${input.size-1}")
}
0