You can remove all remote branches that have been merged to master in one line.
git branch -r --merged master | ack -v master | sed -e 's/\// :/' | xargs -n2 git push
The sed expression should probably not be global, it breaks for branch names with slashes in them.
sed -e 's/\// :/'
Oh nice catch, I'll edit the protip removing the global bit, thanks.