Microsoft interview question

How do you serialize a binary tree?