This is probably pretty basic, but to save me an hour or so of grief can anyone tell me how you can work out the number of bits required to represent a given positive intege
Taking the two based log of the number will report the number of bits required to store it.