You are given N number of weights that are all powers of 2. You are also given an item that weighs 1003 lbs.
(1) Exactly how many of those weights would be needed to balance the weight of the item if you could only use one of each weight?
(2) What's the fewest number of weights you can use to balance the weight of the item if there is an unlimited amount of each weight available to you?
By one definition, a power of 2 must be an integer, yet by another definition, this quantity may be any integer, real number or complex number. If permitted to use this second definition, only one weight is needed to balance the weight of the item weighing 1003 lbs, it would be a weight of 2
log2(1003) lbs (i.e., 1003 lbs).
|
Posted by Dej Mar
on 2009-12-20 10:07:19 |