Question: Getting used to some new code and have a question. All over it, I am seeing the following

file1.cs :

```
MyClass myInstance = MyClass.Instance();

```

...and then in the definition of MyClass there is...

MyClass.cs : 

```
public class MyClass {

   // etc. etc.

   static readonly MyClass _instance = new MyClass();

   public static MyClass Instance() {
      return _instance;
   }

   // etc. etc.

}

```

What's the reason for doing that as opposed to just in file1.cs :

```
MyClass myInstance = new MyClass();

```

?

Answer: 
Because its using single ton pattern that is the reason...

Read : [Singleton](http://www.dofactory.com/net/singleton-design-pattern) - The singleton pattern is a design pattern that is used to ensure that a class can only have one concurrent instance. Whenever additional objects of a singleton class are required, the previously created, single instance is provided.

Read : [Singleton with proper example](http://www.codeproject.com/Articles/430590/Design-Patterns-of-Creational-Design-Patterns#Singleton)
This is the *singleton pattern*. That's why a method is used to get the instance. 

Singleton pattern is used, when we want only one instance of a class be used in our app. We don't want the consumers of our app have the right to build more than one instances. 

For a detailed description of the singleton pattern, please have a look [here](http://en.wikipedia.org/wiki/Singleton_pattern).