I would say its 70% diet and nutrition, 30% exercise - and don't forget rest and stress relief because that is a VIP factor also.
Between 2006 -2012 I ran 5X/week yielding 25-30 miles (also weight trained 2X per week). My weight dropped from 215 to 175 even though my diet was not very strict.
In 2012, I began bumping my run miles (40-45 miles per week) in order to train for an 50 mile ultra-marathon race. Ate a lot of carbs and indulged with pasta, pizza, etc after long runs. I steadily gained weight, 5,10,15 pounds even though I was running more. I ran the race 12 heavier.
Post race dropped the miles back a bit but really focused on diet and clean eating. Lost 20 pounds the next three months. I credit diet control and sleep.
Diet versus exercise challenges differ between person, circumstances and habit.
I keep track of my calories on myfitnesspal as well as record calories burned per mile (minus three miles). I also tend to create 10%ish buffers to make sure I am not too optimistic.
Things I've noticed are that foods with higher carbs make me more hungry. I also get more hungry while tired and stressed or lightly sick.
The best advice I have is to eat foods that are naturally lower in calories than their actual size like apples, bananas, grapes, lettuce, celery etc. Also meaty foods tend to help curve cravings or the food rages that high carbed foods make you feel. I know fruit have carbs, but they are nutrient rich and take up a lot more volume than say a cake or cereal. Drinking lots of fluids actually make me feel more full too. Regular soda is far and away the worst thing for you, bar none. Diet soda isn't good either, but regular soda is cheap calories with no nutrition.
I've noticed that, for me, metabolism is a game you play throughout the day. Eat a little here or there, move around here and there, drink lots of fluids.
For example:
I get up and eat a yogurt, four walnuts and a glass of orange juice. I drink several cups of liquids (various) as i drive to work. I will then walk 1200 steps with 6 floors to my desk. I will periodically get up from my desk to use the rest room or get something to drink, i will use that time as a time to focus on something job related and will get 500-1500 steps.
By lunch I'll have 4000-5000 steps and will have eaten grapes, a banana and a 100 calorie vita top. I will walk 6000 steps on lunch, and get about 8 floors.
Between lunch and 6pm I will eat an apple, a serving of almonds and walk another 2000-4000 steps in periodic movements to use the rr, get something to drink all while thinking of something job related (three/four birds, one stone).
Once 6pm hits I may stay longer or work more. Regardless, I will walk another 6000-20,000 steps, eat a banana, two yogurts, more grapes and sometimes a protein bar and/or tuna crackers and/or light popcorn.
So by the end of the day I will actually walk 20-30k in steps while eating 1500-2200 calories. On the weekends will eat 2500-3500 calories day. I will walk more (by 5-10k a day)and reduce calories (500 a day) when trying to lose weight.
All-in-all, for me, the input versus output seems to work. I will have a few (2-4) days a week of true garbage food time. Ill eat a large mama's pizza or will eat a few baskets of chips with a plate of fajitas. I also cannot over exert physically (run or weightlift) cause I work 50-60 hours at a stressful job, so I walk more throughout the day which is less tiring and raises the motabs all day.