The spectral radius of graphs without long cycles