To represent the situation with an equation, we can use the formula for the perimeter of a rectangle, which is given by:
\[ P = 2l + 2w \]
where \( P \) is the perimeter, \( l \) is the length, and \( w \) is the width.
Given that the perimeter \( P \) is 240 cm and the width \( w \) is 12 cm, we can substitute these values into the equation:
\[ 240 = 2l + 2(12) \]
This can be simplified to:
\[ 240 = 2l + 24 \]
This equation can be used to find the length \( l \).