Thermalization of electrons in gases