chore: fix formatting
Signed-off-by: Matej Focko <mfocko@redhat.com>
This commit is contained in:
parent
d7f8f4fd7b
commit
e3888415f7
5 changed files with 17 additions and 20 deletions
|
@ -14,14 +14,11 @@ impl Reachable {
|
|||
let reaches_pacific = y == 0 || x == 0;
|
||||
let reaches_atlantic = y == max_y - 1 || x == max_x - 1;
|
||||
|
||||
if reaches_atlantic && reaches_pacific {
|
||||
Reachable::Both
|
||||
} else if reaches_atlantic {
|
||||
Reachable::Atlantic
|
||||
} else if reaches_pacific {
|
||||
Reachable::Pacific
|
||||
} else {
|
||||
Reachable::None
|
||||
match (reaches_pacific, reaches_atlantic) {
|
||||
(true, true) => Reachable::Both,
|
||||
(true, _) => Reachable::Pacific,
|
||||
(_, true) => Reachable::Atlantic,
|
||||
(_, _) => Reachable::None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue