## Problem Codeforces language version IDs were wrong (pointed at old compiler versions), `LANGUAGE_VERSIONS` was incomplete for most platforms, the contest picker crashed when `supports_countdown` was stored as a non-table entry, and `:CP stress` restored a broken IO view on exit. ## Solution Correct CF `programTypeId` values and default to C++20. Add `LANGUAGE_VERSIONS` entries for all six platforms. Guard `get_contest_summaries` against non-table cache entries. Call `ensure_io_view()` after stress session restore. Shorten the stress terminal buffer name to a readable `term://stress.py` format.
10 lines
277 B
Rust
10 lines
277 B
Rust
use std::io::{self,Read};
|
|
fn main(){
|
|
let mut s=String::new();
|
|
io::stdin().read_to_string(&mut s).unwrap();
|
|
let s=s.trim().as_bytes();
|
|
let(mut mx,mut c)=(1usize,1usize);
|
|
for i in 1..s.len(){if s[i]==s[i-1]{c+=1;}else{c=1;}if c>mx{mx=c;}}
|
|
println!("{}",mx);
|
|
}
|
|
|