I definitely think bean dipping is definitely the appropriate response in these situations. It sends the message: I am not interested in pursuing that line of conversation.
Any response that acknowledges what they've said merely encourages them, unfortunately, and they'll continue to add to their self-congratulary stories. I often hear people responding by politely encouraging them ("that must have been so interesting!" etc), which is fine if they're happy to continue the conversation along those lines. The other reaction I see is people mocking them by pretending to encourage them - usually using a hearty dose of sarcasm! Which is rude, although often amusing.
So I agree, change the subject!