The length of a rectangle is 1 meter less than twice its width. The perimeter of the rectangle is 40 meters. What is the length of the rectangle?