2020-11-02から1日間の記事一覧

ABC181

https://atcoder.jp/contests/abc181 A: Heavy Rotation n = gets.to_i puts n.even? ? "White" : "Black" B: Trapezoid Sum n = gets.to_i abs = n.times.map {gets.split.map(&:to_i)} puts abs.map {|a, b| (b - a + 1) * (a + b) / 2}.sum C: Collineari…