Everyone is born with a similar number of sweat glands, but they are essentially nonfunctional at first. In a child's first few years of life, a proportion of them become functional depending on the temperature the child is exposed to. The hotter the environment, the more glands that become active. The process lasts a few years and then the number of glands is set for life.
This is what's called "developmental programming," which is an organism's ability to change its phenotype—the interaction of a genotype and the environment—to adapt to its environment. This is similar to "developmental plasticity," only with programming the changes are final, while plasticity can keep changing.
It's not just humans who can have these developmental traits. For example, meadow moles born in autumn have a thicker hair coat than those born in the spring. A thick coat reflects an adaptive programming response to help ensure survival in the cold environment. This shows that "programming is an established biological phenomenon that is exemplified in nature."

