I've got a problem for which I have worked out the asnwer however I have some problems with writting the solution for my classes.
There is a given integral \[n\geq 1\]. For not empty subset of the set X {1,2,...,n} let x and y be respectively the smallest and the biggest element of the set X and let
\[f(X)=\frac{1}{n-(y-x)}\]
Find the sum of the f(X) for all not empty subsets X of the set {1,2,...,n}
Solution: