Task: | Suuremmat |
Sender: | xnor |
Submission time: | 2021-01-23 16:05:55 +0200 |
Language: | Rust |
Status: | READY |
Result: | 0 |
group | verdict | score |
---|---|---|
#1 | WRONG ANSWER | 0 |
#2 | WRONG ANSWER | 0 |
test | verdict | time | group | |
---|---|---|---|---|
#1 | WRONG ANSWER | 0.01 s | 1, 2 | details |
#2 | WRONG ANSWER | 0.01 s | 2 | details |
Code
use std::io::{self, BufRead}; fn main() { let mut lines = io::BufReader::new(io::stdin()).lines(); let t = lines.next().unwrap().unwrap().parse::<usize>().unwrap(); for _ in 0..t { let n = lines.next().unwrap().unwrap(); if n.bytes().all(|b| b == b'9') { for _ in 0..=n.len() { print!("1") } println!(); } else { for _ in 0..=n.len() { print!("{}", n.bytes().next().unwrap() as char); } println!(); } } }
Test details
Test 1
Group: 1, 2
Verdict: WRONG ANSWER
input |
---|
1000 1 2 3 4 ... |
correct output |
---|
2 3 4 5 6 ... |
user output |
---|
11 22 33 44 55 ... Truncated |
Test 2
Group: 2
Verdict: WRONG ANSWER
input |
---|
1000 735425311146082632 756615631808964686 466489470801941584 100417544394053220 ... |
correct output |
---|
777777777777777777 777777777777777777 555555555555555555 111111111111111111 555555555555555555 ... |
user output |
---|
7777777777777777777 7777777777777777777 4444444444444444444 1111111111111111111 4444444444 ... Truncated |