  Let $\mathbb{F}_q$ be a finite field of characteristic not equal to $2$ or
$3$. We compute the weight enumerators of some projective and affine
Reed-Muller codes of order $3$ over $\mathbb{F}_q$. These weight enumerators
answer enumerative questions about plane cubic curves. We apply the MacWilliams
theorem to give formulas for coefficients of the weight enumerator of the duals
of these codes. We see how traces of Hecke operators acting on spaces of cusp
forms for $\operatorname{SL}_2(\mathbb{Z})$ play a role in these formulas.
