An isosceles triangle has a measure of 'p' units for its equal sides and 'q' units for its unequal side. What is its perimeter?