singleton in C++

The Meyers Singleton in C++11 is automatically thread-safe. That is guaranteed by the standard: Static variables with block scope. The elegance of this implementation is that the singleton object instance is a static variable with a block scope. Therefore, instance will exactly be initialized, when the static method getInstance will be executed the first time. 
```
#include <iostream>
using namespace std;

class Singleton {
public:
  static Singleton& getInstance(){
    static Singleton instance;
    return instance;
  }
};

int main()
{
    Singleton s = Singleton::getInstance();
    return 0;
}
```