```python
import math

def area_polygon(s, l):
  """
  Calculates the area of a regular polygon.

  Args:
    s: The number of sides of the regular polygon.
    l: The length of each side.

  Returns:
    The area of the regular polygon.
  """
  return (s * l**2) / (4 * math.tan(math.pi / s))
```