title: How do i check if an item is already exist in a List?
body: <pre><code>if (this.Handle != hwnd &amp;&amp; (Constants.GetWindowLongA(hwnd, Constants.GWL_STYLE) &amp; Constants.TARGETWINDOW) == Constants.TARGETWINDOW)
  {
      StringBuilder sb = new StringBuilder(100);
      Constants.GetWindowText(hwnd, sb, sb.Capacity);
  
      Window t = new Window();
      t.Handle = hwnd;
      t.Title = sb.ToString();
      windows.Add(t);
  }
  </code></pre>
  
  <p>I want to check that if the item variable (t) is already in the List windows don't add it again. Just after the line <code>t.Title = sb.ToString();</code> to check if it's not exist then add it.</p>