The sum of some terms of a GP is 315, whose first term and the common ratio are 5 and 2, respectively. Find the last term and the number of terms.
Let there be terms in the GP with the first term and common ratio .
Then,
Sum of terms
Therefore, the last term