What is a singleton class?
Answers
Answered by
0
In object-oriented programming, a singleton class is a class that can have only one object (an instance of the class) at a time.
After first time, if we try to instantiate the Singleton class, the new variable also points to the first instance created. So whatever modifications we do to any variable inside the class through any instance, it affects the variable of the single instance created and is visible if we access that variable through any variable of that class type defined.
Answered by
9
What is a singleton class?
Your answer is on Attachment..Have a Look ^_^
Attachments:
Similar questions
India Languages,
7 months ago
English,
7 months ago
English,
1 year ago
Social Sciences,
1 year ago
Biology,
1 year ago