title: Hard coded string manipulation vs Xelement when creating XML element
body: <p>In c# if I have to create a new XElement I can use the following two methods.</p>
  
  <p>Method 1</p>
  
  <pre><code>string m = "&lt;address&gt;";
         m += "&lt;addressline1&gt;" + address.Addressline1 + "&lt;/addressline1&gt;";
         m += "&lt;addressline2&gt;" + address.Addressline2 + "&lt;/addressline2&gt;";
         m += "&lt;city&gt;" + address.Addressline1 + "&lt;/city&gt;";
         m += "&lt;postcode&gt;" + address.Addressline1 + "&lt;/postcode&gt;";
         m += "&lt;/address&gt;";
  </code></pre>
  
  <p>Method 2</p>
  
  <pre><code>XElement a = new XElement("address",
                       new XElement("addressline1", address.Addressline1),
                       new XElement("addressline2", address.Addressline2),
                       new XElement("city", address.City),
                       new XElement("postcode", address.postcode)
                                    );
  </code></pre>
  
  <p>Which method is more preferable if my end goal is just to obtain a custom object as XML string?</p>