結果

問題 No.700 LOVE
ユーザー _Clay____
提出日時 2018-10-14 15:09:36
言語 Rust
(1.83.0 + proconio)
結果
AC  
実行時間 1 ms / 2,000 ms
コード長 553 bytes
コンパイル時間 10,907 ms
コンパイル使用メモリ 400,664 KB
実行使用メモリ 6,820 KB
最終ジャッジ日時 2025-01-30 14:37:52
合計ジャッジ時間 11,685 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

use std::io::*;

fn main() {
  let s = stdin();
  let mut handle = s.lock();

  let mut buf = String::new();
  handle.read_line(&mut buf).ok();
  let l: Vec<u16> = buf
    .trim()
    .split_whitespace()
    .map(|e| e.parse().ok().unwrap())
    .collect();

  let mut buf = String::new();
  for _i in 0..l[0] {
    handle.read_line(&mut buf).ok();
    for c in buf.trim().chars().collect::<Vec<char>>().windows(4) {
      if let ['L', 'O', 'V', 'E'] = c {
        println!("YES");
        return;
      }
    }
    buf.clear();
  }
  println!("NO");
}
0