0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

初心者プログラマーがAtCoderに挑んだ軌跡-ABC406-A-

Posted at

ABC406-A

問題の内容

時刻の前後

言語

Rust

解法

時間で前後を判定したのち、もし時間が一致していたら分で分ける

課題

特になし

学んだこと

flag処理

提出内容

use proconio::input;

fn main() {
  input! {
    a: i64,
    b: i64,
    c: i64,
    d: i64,
  }
  let mut flag = true;
  if a < c {
    flag = false;
  } else if a == c && b < d {
    flag = false;
  }
  if flag {
    println!("Yes");
  } else {
    println!("No");
  }
}

成績

  • 292Byte
  • AC
  • 1ms
  • 2088KiB
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?