Wrote a rough draft of Solver