Hacker News new | ask | show | jobs
by highphive 62 days ago
That's a good point, you could surely model full chess in a single dimension, it would just be that each pieces' movement rules would be more confusing

E.g. a pawn can move exactly 8 squares towards its opponents end (16 on its first move if no piece occupies 8 squares away), but can only capture 7 or 9 squares forward (with some extra modulo math to prevent wrapping)

1 comments

Yeah and it'd be even worse if you want to flatten out the piece colors and types into the 1D array.