Simple combinatorial PAL/GAL reader

The variable b is only a 'temporary' storage in your code to store a character. It gets the value '1' or '0' and that is appended to the out variable.