The maximum number of electrons that can be accommodated in an electron shell is given by the formula 2n², where 'n' is the principal quantum number of the shell.