In my opinion:
Eating less and exercising more=weight loss. This has NOTHING to do with the types of food or nutrients consumed. I can consume nothing but "bad" carbs all day every day, yet I won't gain a pound if those calories consumed are kept low. In addition, the amount of exercise performed will boost the rapidity of weight loss.
On the other hand, eating more and exercising less=weight gain. Again, though, this has nothing to do with the types of food or nutrients consumed. If I eat an excessive number of calories from nothing but brown rice, or oatmeal in water, or kale, I WILL gain weight. Additionally, lack of exercise will speed the rapidity of weight gain.
Bottom line is if you eat a food that is chemically "right" for your body you will lose weight, if you eat foods that are chemically "wrong" for your body you will gain weight regardless of calorie content due to inflammatory reactions which if they continue long enough lead to thyroid and other hormonal imbalances...And since most people are eating processed crap with 100's of ingredients in it its almost impossible to NOT be eating something that your body is reactive to pretty much every day or even multiple times every day. The more ingredients you consume in a given day, the higher the likelihood that you are eating something that will cause you to gain inflammatory body weight.
Bottom line. Period.
There is a reason why so many people get in a "rut" and can't lose weight even though they are eating "healthy" foods. There is no such thing as a universally healthy food, only foods that are healthy for your body chemistry. You might do great with Oats, Blueberries and Whey Protein. Your friend eats the same thing and gets bloated and gains weight. If he continues to eat this on a daily basis, it turns into low grade chronic inflammation which leads to many issues, least of all weight gain or no weight loss.
Here is the research done
http://medicalxpress.com/news/2015-11-healthy-foods-differ-individual.html which backs up this person's 30,000+ person evidence in her practice that has been going on for years and years with tremendous results including many cases of completely reversing thyroid problems.
http://lyngenet.com/
How do I know this? Because I tried it myself and lost 25 lbs in 30 days, almost as if by magic, and I wasn't starting out fat. I was in pretty good shape. When I ate a food that my body "didn't like" such as eggs or potatoes I gained weight---sometimes lots of it...1.8 lbs from a single egg while keeping everything the same otherwise from the day before. Over 2 lbs from a single potato. When I ate foods that my body "liked" I lost weight...usually in the 1-2 lb range but sometimes over 3 lbs...
What a lot of people think is "fat" is actually inflammatory weight being held in by your body, especially in the intestinal area which in a lot of people is being served a constant dose 3-4 times a day of foods that the body is reactive to. When you correct the food problem, the body starts becoming less inflamed, holding in less water and auto-correcting the hormonal issues that have been caused over long periods of time, and it does this pretty damn quickly...
So does overeating cause people to become fat? Hell yeah. But most people also have years of chronic low grade inflammation built up which is holding a ton of weight in, probably more than the fat you think you need to lose.