I lost weight and it was pretty easy by simply keeping track of the calories I consumed. There are plenty of calorie counters out there. The one I have used and LOVE is "my fitness pal". They have an app for your phone and website and its all free which makes recording food a breeze and they have the nutrition facts for nearly anything imaginable. Fast food, restaurants, home cooking etc. At the beginning you set it up with your current stats and as you lose weight it adjusts your goal caloric intake to help you meet your overall goals. You can record water and exercise too and it's great to do with a friend as you can keep tabs on each other if you choose. It records all nutritional consumption. Not just calories.
For answering that question the motivation for exercising is quite important. Is it the desire for having a “bikini” body, weight management, being fit and healthy or all of them? To support the most common areas a balanced diet will support most of your dreams, eat fresh, vitamin and mineral rich food, reduce the intake of processed food (high on sugar, salt, preservatives, etc) and enjoy life by being active with friends/family on fresh air and have fun.