how can I get rid of the problem of Gas?
Like bimjob said, don't overeat certain foods. For me cabbage and brussel sprouts are the most problematic because not only to they cause gas but particularily foul smelling gas.
In addition to the already mentioned Beano you can take activated charcoal tablets.
Limit your intake of brasicas (broccoli, cabbage, cauliflower) and beans (baked bean types, not green beans). Take Beano. It's made for your problem.