title: XML serialization array in C#
body: <p>I'm having trouble figuring this out, I have an xml sheet that looks like this</p>
  
  <pre><code>&lt;root&gt;
    &lt;list id="1" title="One"&gt;
      &lt;word&gt;TEST1&lt;/word&gt;
      &lt;word&gt;TEST2&lt;/word&gt;
      &lt;word&gt;TEST3&lt;/word&gt;
      &lt;word&gt;TEST4&lt;/word&gt;
      &lt;word&gt;TEST5&lt;/word&gt;
      &lt;word&gt;TEST6&lt;/word&gt;   
    &lt;/list&gt;
    &lt;list id="2" title="Two"&gt;
      &lt;word&gt;TEST1&lt;/word&gt;
      &lt;word&gt;TEST2&lt;/word&gt;
      &lt;word&gt;TEST3&lt;/word&gt;
      &lt;word&gt;TEST4&lt;/word&gt;
      &lt;word&gt;TEST5&lt;/word&gt;
      &lt;word&gt;TEST6&lt;/word&gt;   
    &lt;/list&gt;
  &lt;/root&gt;
  </code></pre>
  
  <p>And I'm trying to serialize it into</p>
  
  <pre><code>public class Items
  {
    [XmlAttribute("id")]
    public string ID { get; set; } 
  
    [XmlAttribute("title")]
    public string Title { get; set; }   
  
    //I don't know what to do for this
    [Xml... something]
    public list&lt;string&gt; Words { get; set; }   
  }
  
  //I don't this this is right either
  [XmlRoot("root")]
  public class Lists
  {
    [XmlArray("list")]
    [XmlArrayItem("word")]
    public List&lt;Items&gt; Get { get; set; }
  }
  
  //Deserialize XML to Lists Class
  using (Stream s = File.OpenRead("myfile.xml"))
  {
     Lists myLists = (Lists) new XmlSerializer(typeof (Lists)).Deserialize(s);
  }
  </code></pre>
  
  <p>I'm really new with XML and XML serializing, any help would be much appreciated</p>