結果
| 問題 | No.380 悪の台本 |
| コンテスト | |
| ユーザー |
kuuso1
|
| 提出日時 | 2016-09-03 00:58:42 |
| 言語 | F# (F# 10.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 1,127 bytes |
| 記録 | |
| コンパイル時間 | 12,225 ms |
| コンパイル使用メモリ | 212,156 KB |
| 実行使用メモリ | 38,528 KB |
| 最終ジャッジ日時 | 2026-05-07 05:35:53 |
| 合計ジャッジ時間 | 11,973 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 1 WA * 7 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (230 ミリ秒)。 main -> /home/judge/data/code/bin/Release/net10.0/main.dll main -> /home/judge/data/code/bin/Release/net10.0/publish/
ソースコード
open System
open System.Text.RegularExpressions
let ri () = stdin.ReadLine() |> int
let ria () = stdin.ReadLine().Split() |> Array.map int
type Sol() =
member this.Solve() =
let okMsg = "CORRECT (maybe)"
let ngMsg = "WRONG!"
let judgeWords (s :string) =
let ss = s.Split()
match (ss.[0] ,s) with
| ("digi",_ ) when Regex.Match(s,"[nN][yY][oO]\W{0,3}$").Success -> okMsg
| ("petit",_ ) when Regex.Match(s,"[nN][yY][uU]\W{0,3}$").Success -> okMsg
| ("rabi",_ ) when Regex.Match(s,"\w").Success -> okMsg
| ("gema",_ ) when Regex.Match(s,"[gG][eE][mM][aA]\W{0,3}$").Success -> okMsg
| ("piyo",_ ) when Regex.Match(s,"[pP][yY][oO]\W{0,3}$").Success -> okMsg
| (_,_ ) -> ngMsg
let mutable chk = true
let mutable input :string = ""
while chk do
input <- stdin.ReadLine()
chk <- String.IsNullOrEmpty(input) |> not
if chk then input |> judgeWords |> printfn "%s"
let mySol = new Sol()
mySol.Solve()
kuuso1