In a square, the sum of the lengths of three sides is 45 and in a rectangle the difference between a length and a width is 5 in. if a width of the rectangle is the same as a side of the square, how long is a length of the rectangle?
a. 20
b. 22
c. 15
d. 24