Find the sum of the series 1+2+4+8+16+............+2^(n-1) up to n terms.