Exercise in moderation is good for you.
It does not guarantee no heart problems. Many people who consistently exercise have had hear problems and hear attacks.
My brother is one such.
Depends on type of exercise. Worst exercise for heart is lifting weights or using weight machines. Only thing I ever do in the gym is use treadmill to walk briskly.