Context. During solar flares an enormous amount of energy is released, and the charged particles, like electrons, are accelerated. These non-thermal electrons interact with the plasma in various parts of solar flares, where the distribution function of electrons can therefore be non-Maxwellian. Aims. We focus on the non-thermal components of the electron distribution in the keV range and analyse high-energy resolution X-ray spectra detected by RESIK and RHESSI for three solar flares. Methods. In the 2-4 keV range we assume that the electron distribution can be modelled by an n-distribution. Using a method of line-intensity ratios, we analyse allowed and satellite lines of Si observed by RESIK and estimate the parameters of this n-distribution. At higher energies we explore RHESSI bremsstrahlung spectra. Adopting a forward-fitting approach and thick-target approximation, we determine the characteristics of injected electron beams. Results. RHESSI non-thermal component associated with the electron beam is correlated well with presence of the non-thermal n-distribution obtained from the RESIK spectra. In addition, such an n-distribution occurs during radio bursts observed in the 0.61-15.4 GHz range. Furthermore, we show that the n-distribution could also explain RHESSI emission below ∼5 keV. Therefore, two independent diagnostics methods indicate the flare plasma being affected by the electron beam can have a non-thermal component in the ∼2-5 keV range, which is described by the n-distribution well. Finally, spectral line analysis reveals that the n-distribution does not occupy the same location as the thermal component detected by RHESSI at ∼10 keV.