結果

問題 No.1543 [Cherry 2nd Tune A] これがプログラミングなのね
ユーザー DieGoDieGo
提出日時 2021-07-22 12:11:40
言語 Elixir
(1.16.2)
結果
RE  
実行時間 -
コード長 450 bytes
コンパイル時間 3,206 ms
コンパイル使用メモリ 54,908 KB
実行使用メモリ 53,420 KB
最終ジャッジ日時 2023-09-24 13:52:15
合計ジャッジ時間 25,962 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 WA -
testcase_02 RE -
testcase_03 WA -
testcase_04 WA -
testcase_05 RE -
testcase_06 WA -
testcase_07 WA -
testcase_08 RE -
testcase_09 RE -
testcase_10 RE -
testcase_11 WA -
testcase_12 WA -
testcase_13 RE -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 RE -
testcase_20 WA -
testcase_21 WA -
testcase_22 WA -
testcase_23 RE -
testcase_24 RE -
testcase_25 RE -
testcase_26 RE -
testcase_27 RE -
testcase_28 WA -
testcase_29 WA -
testcase_30 WA -
testcase_31 WA -
testcase_32 WA -
testcase_33 WA -
testcase_34 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

defmodule Main do
  def main do
    [s, t, c] = IO.read(:line) |> String.trim() |> String.split(" ");
    si = String.to_integer(s); ti = String.to_integer(t);

    cond do
      String.equivalent?(c, "<") -> if si < ti, do: IO.puts "YES", else: IO.puts "NO"
      String.equivalent?(c, ">") -> if si > ti, do: IO.puts "YES", else: IO.puts "NO"
      String.equivalent?(c, "=") -> if si == ti, do: IO.puts "YES", else: IO.puts "NO"
    end
  end
end
0