Determine the number of terms of the arithmetic
sequence whose first and last terms are 11 and
81 respectively, given that
the sum of all its terms is 506.
The formula for the sum of an arithmetic sequence is
Let , , and .