```scala

(1 to MaxZoomLevel).map(resolution(_,i)).find(resWithEp >= _) match {
 ...
}
```