Do whatever exercise works for you. For some it'll be lifting weights in the gym, for others it's something else. I've tried the gym but it didn't really work for me. I enjoy mountain biking, running and for a long time went swimming every lunchtime. Those activities just worked better for me. Someone was suggesting climbing which is another good activity if you want to involve your mind as well as your body.
You'll still get the benefit of being away from your work for a short while, doing something physical and focussing on improving at something else.
You'll still get the benefit of being away from your work for a short while, doing something physical and focussing on improving at something else.