Deloitte interview question

How can you stop clone in a singleton java class?

Interview Answer

Anonymous

20 May 2020

Overide clone method and inside, throw new CloneNotSupportedException();

1