aizu_online_judge/dpl/
dpl_1_d.rs1#[doc(no_inline)]
2pub use competitive::combinatorial_optimization::LongestIncreasingSubsequence;
3use competitive::prelude::*;
4
5#[verify::aizu_online_judge("DPL_1_D")]
6pub fn dpl_1_d(reader: impl Read, mut writer: impl Write) {
7 let s = read_all_unchecked(reader);
8 let mut scanner = Scanner::new(&s);
9 scan!(scanner, n, a: [u64]);
10 let mut lis = LongestIncreasingSubsequence::new();
11 lis.extend(a.take(n));
12 writeln!(writer, "{}", lis.longest_length()).ok();
13}