Changes:
  - inlined `map` in `solve` function due to termination checker issues