A note on 'Bits as Configuration' - instead of assigning the values 1, 2, 4 & 8 manually you can use iota.
FlagA = (1 << iota)
Makes it easier to reorder and introduce new flags.
Markus, yes thanks for pointing that out.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.