This is a homework question that I am stuck with.
Consider unsigned integer representation. How many bits will be required to store a decimal number
The formula for the number of binary bits required to store n integers (for example, 0 to n - 1) is:
and round up.
For example, for values -128 to 127 (signed byte) or 0 to 255 (unsigned byte), the number of integers is 256, so n is 256, giving 8 from the above formula.
For 0 to n, use n + 1 in the above formula (there are n + 1 integers).
On your calculator, loge may just be labelled log or ln (natural logarithm).