title: How to add a new object to a list without a variable?
body: <p>I am trying to add a new instance of my asd class to a list by constructing a new asd and then adding that, but Unity gives an Object not set to instance of object error.</p>
  
  <pre><code>using UnityEngine;
  using System.Collections;
  using System.Collections.Generic;
  
  public class asd {
      public int a = 0;
      public string s = "asd";
  
      public asd (int apop, string ssdf) {
          a = apop;
          s = ssdf;
      }
  }
  
  public class test : MonoBehaviour {
  
      public List&lt;asd&gt; list;
  
      // Use this for initialization
      void Start () {
          list.Add (new asd(1, "yeee"));
          list.Add (new asd(456, "oooo"));
      }
  
      // Update is called once per frame
      void Update () {
  
      }
  }
  </code></pre>