I think matching the `position` result can be great:
```rust
let begin = match seq.iter().position(|c| *c == '\n' as u8) {None => continue, Some(c) => c};
let end = len - 1;
```
I'll change that.