Beautiful Code interview question

How do you implement your own Context manager in Python?