Suppose we have to predict the class of output from a neural network. I want to get the class type, and the numerical value that represents the class type obtained at the first output neuron.
Traditionally you would use one output neuron for each class. You can try a "bit-by-bit" approach but I believe that you will have problem with training of the network. If you need a single result, I suggest you just add an encoder to the output layer (e.g. 8-to-3 or 16-to-4). This can be done digitally (Boolean logic), or by another layer of neurons (with simple OR configuration).