Existence of solution for nonlinear wave equation with variable exponents