Added BoardRep class with nicer bounds checking