Prove that every positive integer can be expressed as a sum of numbers of the kind $2^i3^j$, where no term in the summation divides the other.
For example :
1) 14 = 8 + 6 is a valid representation, while 14 = 2 + 4 + 8 is invalid since 2|4 and 2|8.
2) 20 = 12 + 8 is fine, but 20 = 18 + 2 is not valid.
Can you find this representation algorithmically.
Posted: Jun 06 '12
Seen: 35 times
Last updated: Jun 06 '12
Longest increasing subsequence
Longest increasing digital subsequence
Exact Algorithms for Subset Sum