How do you build muscle and lose weight at same time?

I stopped working out about three weeks ago due to holidays but will start back again tomorrow. I was battling the bulge to begin with but have gained excess poundage due to my retreat from the weight room. Is it possible to maintain or even gain muscle while losing weight (i. e. body fat)?
How do you build muscle and lose weight at same time?
Post Opinion