Haskell Quiz/Bytecode Compiler
The Problem
Create a bytecode compiler as described on the test page. The Ruby solution involves being run by a interpreter written in Ruby - but that wont' work for the Haskell solution. Anyone want to write the interpreter in Haskell to test the solutions? :)
Solutions
- A (non-monadic) solution to the parsing and eval part of this quiz is a case study in Chapter 17 of The Craft of Functional Programming by Simon Thompson.