Body weight depends on a multitude of factors, and, as you might imagine, both lifestyle and genetics play critical roles. The key to weight control is balancing energy intake with energy expenditure, a relationship that is often referred to as the energy balance equation.
Energy input comes from the food and drink we consume and is usually measured in kilocalories (kcal). The U.S. Department of Agriculture assigns calorie levels based on an individual's sex, age and activity level. The intake quantities range from 3,000 kcal for active males between 19 and 20 years of age to 2,000 kcal for sedentary males 76 and up. (The corresponding numbers for females are 2,400 kcal and 1,600 kcal, respectively.) When energy intake is greater than energy expenditure the body will store excess energy as fat, regardless of whether those excess kcals came from fat, carbohydrate, protein or even alcohol.
Energy expenditure consists of three components: resting metabolic rate (BMR), which is the energy your body uses to maintain normal function throughout the day; diet induced thermogenesis (DIT), the energy needed to digest, absorb, transport, metabolize and store food and drink; and physical activity. In the sedentary individual BMR typically accounts for 60 to 75 percent of energy expenditure, DIT is responsible for about 10 percent and physical activity between 10 and 25 percent. (As you might expect, active individuals will have a greater proportion of energy expenditure accounted for by physical activity.) Our bodies are expending energy all the time. Even while asleep the body requires energy to fuel the multitude of complex functions required to keep us alive.
Since one pound of body fat is equivalent to about 3,500 kcal of energy, the energy balance equation suggests that an increase in food intake or a decrease in energy expenditure equal to 3,500 kcal will result in a weight gain of one pound. Conversely, a weight loss of one pound will result for every 3,500 kcal worth of food not eaten or an equal amount of increased expenditure. Although this is a good rule of thumb for predicting either weight gain or loss, there are considerable individual differences that the energy balance equation does not account for. Weight change is a relatively slow process—taking place over longer periods than just mere minutes, hours or days. Weight gain, for instance, involves a long-term state where caloric intake exceeds expenditure.
And thus the answer to a question like the one posed here cannot really be answered unless we know all the other aspects of an individual's lifestyle. It is true to say that had someone gone for a brisk walk rather than, say, taking an afternoon nap, they would have utilized more energy for the duration of the walk.
Sleeping itself, however, is not the cause of weight gain. As we have seen above, the key is really energy balance over extended periods of time. Unfortunately, in the U.S. many people are consuming more energy than their bodies can use (or than they are using), which has led to a situation of epidemic proportions where over one third of all adults are now obese.
Interestingly, there have been a few recent studies indicating that individuals who either suffer from sleep deprivation or get only limited amounts of sleep may be more susceptible to weight gain than those who get adequate sleep. It appears that lack of sleep leads to decreased release of the hormone leptin—higher levels of which confer a feeling of fullness, whereas low levels can result in feelings of hunger. In addition, sleep loss increases levels of the hormone grehlin, which also makes people feel more hungry.