See Jon Skeet's Stack Overflow and Personal Emails. With rare exception, contacting someone privately, particularly to ask a question (which should instead be posted on the site as normal) can look pretty creepy pretty easily.
If you have a Stack Overflow question, ask it on Stack Overflow (repeat for any relevant site).
If, in the rare case where you and this person have actually built up a bit of a friendship (via chat, publicly posted, non-invasive stuff like Twitter) sure, go ahead and ask though. I've added several people from Arqade to my Steam friends because hey, we know each other, we play games, why not. I've added several people on Twitter because it's a public, low friction venue and I recognize their names. When it starts off as much more than "I know you, you know me, let us add each other on (social network/chat program)" it gets into the creepy zone fast.