結果
問題 | No.761 平均値ゲーム |
ユーザー |
|
提出日時 | 2019-04-20 14:49:59 |
言語 | Ruby (3.4.1) |
結果 |
AC
|
実行時間 | 374 ms / 2,000 ms |
コード長 | 277 bytes |
コンパイル時間 | 130 ms |
コンパイル使用メモリ | 7,424 KB |
実行使用メモリ | 24,448 KB |
最終ジャッジ日時 | 2024-10-01 08:33:01 |
合計ジャッジ時間 | 21,123 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
外部呼び出し有り |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 100 |
コンパイルメッセージ
Main.rb:8: warning: mismatched indentations at 'end' with 'if' at 6 Syntax OK
ソースコード
n,*a=`dd`.split.map &:to_i*s=0n.times{|i|s<<s[i]+a[i]}#p sf=->l,r{if a[r-1] == a[l]return trueendth = a.bsearch_index{|e|e>=(s[r]-s[l]+r-l-1)/(r-l)}l_hand = !f[l, th]r_hand = !f[th, r]return l_hand || r_hand}puts f[0,n]?:First: :Second