OneCloud interview question

How to write a singleton pattern?