結果

問題 No.651 E869120 and Driving
ユーザー gemmarogemmaro
提出日時 2020-04-17 10:14:45
言語 Elixir
(1.16.2)
結果
AC  
実行時間 679 ms / 1,000 ms
コード長 321 bytes
コンパイル時間 2,214 ms
コンパイル使用メモリ 53,636 KB
実行使用メモリ 50,096 KB
最終ジャッジ日時 2023-08-30 00:20:11
合計ジャッジ時間 10,099 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 645 ms
49,364 KB
testcase_01 AC 679 ms
49,644 KB
testcase_02 AC 561 ms
49,872 KB
testcase_03 AC 568 ms
49,160 KB
testcase_04 AC 567 ms
49,184 KB
testcase_05 AC 575 ms
50,096 KB
testcase_06 AC 564 ms
49,852 KB
testcase_07 AC 563 ms
49,360 KB
testcase_08 AC 568 ms
49,248 KB
testcase_09 AC 573 ms
49,964 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

defmodule Main do
  def main do
    IO.read(:line)
    |> String.trim()
    |> String.to_integer()
    |> solve
    |> IO.puts()
  end

  def solve(a) do
    m = (a * 60) |> div(100)

    [(m |> div(60)) + 10, m |> rem(60)]
    |> Enum.map(&(&1 |> to_string |> String.pad_leading(2, "0")))
    |> Enum.join(":")
  end
end
0