title: Using static variables in Android
body: <p>In android, are using static variables a recommended practice?
  E.g, implementing a <strong>Singleton pattern in Java</strong>, I usually do:</p>
  <pre><code>private static A the_instance;
  public static A getInstance() {
      if (the_instance == null) {
         the_instance = new A();
      }
      return the_instance;
  }
  </code></pre>
  <p>Also, when does this get cleaned up by the Android JVM?</p>