Sum of numbers of 3^0, 3^1, 3^2 and 3^3 will be 40. Using a combination of these numbers, each occurring at the most once, we can obtain all numbers from 1 to 40 by using the operation of only addition and/or subtraction. For example 39=3^1+ 3^2 + 3^3, 29= 3^1+ 3^3 3^0 ... 
