結果

問題 No.423 ハムスター語初級(数詞)
ユーザー chike_pluschike_plus
提出日時 2019-03-31 13:47:33
言語 F#
(F# 4.0)
結果
AC  
実行時間 49 ms / 2,000 ms
コード長 351 bytes
コンパイル時間 5,004 ms
コンパイル使用メモリ 158,960 KB
実行使用メモリ 23,664 KB
最終ジャッジ日時 2023-08-13 17:41:04
合計ジャッジ時間 6,222 ms
ジャッジサーバーID
(参考情報)
judge10 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 47 ms
23,552 KB
testcase_01 AC 47 ms
21,512 KB
testcase_02 AC 46 ms
21,680 KB
testcase_03 AC 48 ms
23,664 KB
testcase_04 AC 48 ms
21,760 KB
testcase_05 AC 49 ms
19,520 KB
testcase_06 AC 48 ms
23,556 KB
testcase_07 AC 47 ms
23,528 KB
testcase_08 AC 48 ms
21,572 KB
testcase_09 AC 47 ms
21,580 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) F# Compiler version 11.0.0.0 for F# 5.0
Copyright (c) Microsoft Corporation. All Rights Reserved.

ソースコード

diff #

let ``No.423 ハムスター語初級(数詞)``() =
  
  let n = stdin.ReadLine()
  System.Convert.ToInt32( n.Replace("hamu", "1").Replace("ham", "0") , 2)
  |> fun num -> System.Convert.ToString(num * 2, 2)
  |> fun str -> str.Replace("1" , "hamu").Replace("0", "ham")
  |> stdout.WriteLine

  ()
``No.423 ハムスター語初級(数詞)``()
0