I've been working on a method of generating & validating serial numbers for different applications that I'm developing, and am having issues working out exactly where to go from here.
I can generate a serial based on information provided in a few fields (names, version numbers, that kind of thing) and validate that easily enough, but what I'd really like to be able to do is select different 'features' for any given product and be able to see what features are 'enabled' by a given serial number.
From my understanding, it's possible to do something along these lines using something to do with different powers of 2, i.e. if option A = 1, B = 2, C = 4, D = 8 and E = 16, and we were to validate a value of 19, we would be able to tell that option A, B, and E were selected.
Is there an easy way for me to begin working on this that someone has previously come across, or could someone point me to any documentation?