Context. Observations of hydrogen Balmer lines in solar flares remain an important source of information on flare processes in the chromosphere during the impulsive phase of flares. The intensity profiles of optically thick hydrogen lines are determined by the temperature, density, and ionisation structure of the flaring atmosphere, by the plasma velocities and by the velocity distribution of particles in the line formation regions. Aims. We investigate the role of non-thermal electrons in the formation regions of Hα, Hβ, and Hγ lines in order to unfold their influence on the formation of these lines. We concentrate on pulse-beam heating varying on a subsecond timescale. Furthermore, we theoretically explore possibility that a new diagnostic tool exists indicating the presence of non-thermal electrons in the flaring chromosphere based on observations of optical hydrogen lines. Methods. To model the evolution of the flaring atmosphere and the time-dependent hydrogen excitation and ionisation, we used a 1-D radiative hydrodynamic code combined with a test-particle code that simulates the propagation, scattering, and thermalisation of a power-law electron beam in order to obtain the flare heating and the non-thermal collisional rates due to the interaction of the beam with the hydrogen atoms. To not bias the results by other effects, we calculate only short time evolutions of the flaring atmosphere and neglect the plasma velocities in the radiative transfer. Results. All calculated models have shown a time-correlated response of the modelled Balmer line intensities on a subsecond timescale, with a subsecond timelag behind the beam flux. Depending on the beam parameters, both line centres and wings can show pronounced intensity variations. The non-thermal collisional rates generally result in an increased emission from a secondary region formed in the chromosphere. Conclusions. Despite the clear influence of the non-thermal electron beams on the Balmer line intensity profiles, we were not able on the basis of our simulations to produce any unambiguous diagnostic of non-thermal electrons in the line-emitting region, which would be based on comparison of individual Balmer line intensity profiles. However, fast line intensity variations, well-correlated with the beam flux variations, represent an indirect indication of pulsating beams.