In a white dwarf due to high temperature and pressure the electrons of atoms are compressed to a very small space and this makes it impossible to add more electrons in the space as all the energy levels are previously filled and thus the electrons exerts a pressure which acts against the compressive force of the gravity in a white dwarf .