Electron configurations differ for elements with atomic numbers (Z) less than 20 and greater than 90 primarily due to the filling of subshells. For Z<20, the order follows the Aufbau principle, with the sequence 1s<2s<2p<3s<3p<4s<3d<4p. In contrast, for Z>90, particularly in actinides, the f subshell begins to fill, altering the configuration to 1s<2s<2p<3s<3p<3d<4s<4p. The discussion also highlights that while 4s is filled before 3d in lower Z elements, this order is maintained in higher Z elements, but the f subshell's involvement changes the overall configuration. Understanding these differences is crucial for grasping the complexities of electron configurations across the periodic table.