Multiple solutions for nearly resonant nonlinear Dirichlet problems