Skinks that lost their legs evolved them again because of selective pressures imposed by their environment. Snakes, which lack limbs, are highly successful in certain environments, so it's likely that these skinks evolved new limbs to gain a competitive edge. These new limbs enabled them to move more efficiently, climb trees, and access new sources of food. Additionally, having limbs allowed them to better escape from predators and navigate their environment. Ultimately, the evolution of new limbs provided these skinks with an adaptive advantage that increased their chances of survival and reproduction.