結果
| 問題 | No.678 2Dシューティングゲームの必殺ビーム |
| コンテスト | |
| ユーザー |
tak
|
| 提出日時 | 2018-05-01 06:40:56 |
| 言語 | F# (F# 10.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 735 bytes |
| 記録 | |
| コンパイル時間 | 5,166 ms |
| コンパイル使用メモリ | 210,272 KB |
| 実行使用メモリ | 39,296 KB |
| 最終ジャッジ日時 | 2026-03-16 07:05:46 |
| 合計ジャッジ時間 | 10,368 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 11 RE * 7 |
コンパイルメッセージ
復元対象のプロジェクトを決定しています... /home/judge/data/code/main.fsproj を復元しました (165 ミリ秒)。 main -> /home/judge/data/code/bin/Release/net10.0/main.dll main -> /home/judge/data/code/bin/Release/net10.0/publish/
ソースコード
module Program
let read() = stdin.ReadLine().Split() |> Array.map int
let XL(x, _, _, _) = x
let YU(_, x, _, _) = x
let XR(_, _, x, _) = x
let YD(_, _, _, x) = x
let width, height = 1280 + 500, 1680 + 500
let N, xLB, xRB =
let t = read()
t.[0], t.[1] + 500, t.[2] + 500
let info =
Array.init N (fun _ ->
let t = read() |> Array.map ((+) 500)
(t.[0], t.[1], t.[2], t.[3]))
let front = Array.zeroCreate (width + 1)
for t in info do
let YD = YD t
for idx in (XL t)..(XR t) do
front.[idx] <- max front.[idx] YD
for t in info do
let YD = YD t
front.[(max xLB (XL t))..(min xRB (XR t))]
|> Array.exists ((=) YD)
|> function
| true -> 1
| _ -> 0
|> printfn "%i"
tak