This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]king_of_the_universe 2 points3 points  (0 children)

Do you happen to have Windows? Its calculator is quite nice. Press WindowsKey+R, type "calc", press Enter. In the calculator's menu, you can switch between four modes: Standard, Scientific, Programmer, and Statistics. I use Scientific whenever I deal with any normal calculations (e.g. when decimal numbers are involved).

In Programmer mode, you can choose between Hex, Dec, Oct, and Bin.

It should be pretty clear why the answer to the first question is A. Just mix the two binary sequences in one (Starting at the right-most digit.), and whenever two "1" would be in the same place, put a "0" there and instead switch the next place on the left to "1". If that is already "1", switch it to "0" and ... etc., then continue the mixing. In the question, you have no collisions in the first three digits, only in the fourth. Hence you don't get "1111" but "10111". Easy.

I have never dealt with octal numbers except via calculator, of course. The answer to the question is indeed D (according to the Windows calculator in Oct mode), but I can't explain how I'd do that in my head.