The symptoms that you have, i.e pain relived by taking food and occuring again after 3-4 hours, are typical of duodenal ulcer. Avoid smoking, alcohol, pickled food, smoked food and meat. Drink plenty of water, eat fresh vegetables and fruits, have curd daily and exercise regularly.
Next Steps
Get an endoscopy done. Also get tested for H. Pylori infection by urea breath test or endoscopic biopsy if ulcer is visible on endoscopy.
Health Tips
Avoid taking pain medications as they can aggravate your condition. Also avoid staying on empty stomach.