The Shorter The Better

Alice and Bob wants to send a binary number (base 2) with 2400 digits to Chris. However, the internet speed is ridiculously slow and transmit such a long number can take forever. In order to shorten the length of the number, each of them propose a plan :

Alice: we should convert the number to base 64.
Bob: we should convert the number to base 16.

Let the number generated by Alice and Bob be A A and B B respectively, and d ( x ) d(x) denote the number of digits in x x .

Which option best describe the value of d ( A ) d ( B ) \dfrac{d(A)}{ d(B)} ?

1 4 \frac14 3 1 \frac31 3 2 \frac32 1 3 \frac13 4 3 \frac43 2 3 \frac23 3 4 \frac34 4 1 \frac41

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

A way to think about this is to notice that to translate a number from binary to hexadecimal, 4 bits collapse into a single hexadecimal digit. But, to translate a number from binary to base-64, 6 bits collapse into a single digit.

To see why, notice that 4 4 bits describe 16 16 distinct numbers, which can be done with just one hexadecimal digit. And similarly for base-64 numerals

This is why 4 6 \frac{4}{6} times the space is needed.

The number of different things (read numbers ) that one can describe with 2400 binary digits is 2 2400 2^{2400} .

To describe the same number of things using hexadecimal digits, we just need l o g 16 2 2400 log_{16}2^{2400} . And similarly, with base 64, we need l o g 64 2 2400 log_{64}2^{2400}

So, the answer is log 64 2 2400 log 16 2 2400 = log 64 2 log 16 2 = 1 6 log 2 1 4 log 2 = 2 3 \frac{\log_{64}2^{2400}}{\log_{16}2^{2400}}= \frac{\log_{64} 2}{\log_{16} 2} = \frac{\frac{1}{6} \log 2}{\frac{1}{4} \log 2} = \frac{2}{3}


Agnishom Chattopadhyay - 4 years, 9 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...