5. If a line bisects both the area and the perimeter of a triangle, then the line must pass through the ( ) of the triangle.
(A) incenter
(B) circumcenter
(C) centroid
(D) orthocenter
5. (A)

Let the line that bisects the area and perimeter of $\triangle A B C$ intersect $A B$ and $A C$ at $D, E$, and let $I$ be the incenter of $\triangle A B C$, and $r$ be the radius of its incircle. Then we have
$$
S_{\text {IEAD }}=\frac{1}{2} r(A E+
$$
$A D)$,
$$
S_{B C E I D}=\frac{1}{2} r(B D+B C+C E) \text {. }
$$

Since line $E D$ bisects the perimeter of the triangle, we have
$$
A E+A D=B D+B C+C E \text {, }
$$

Thus, $S_{I E A D}=S_{B C E I D}$.
Given that $S_{\triangle A D E}=S_{B C E D}$,
it follows that $S_{\triangle I D E}=0$, meaning line $D E$ passes through $I$.