title: structures of logical operators in C #
body: <p>my query is simple, as I do, if possible, the following in C #. </p>
  
  <pre><code>&lt;html&gt;
  &lt;head&gt;
  &lt;script src="../jquery-1.3.2.js" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
      $(function(){
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(false || null || \"1º\" || \"2º\")&lt;/span&gt; : &lt;span&gt;"+(false || null || "1º" || "2º")+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(false &amp;&amp; null || false || \"2º\")&lt;/span&gt; : &lt;span&gt;"+(false &amp;&amp; null || false || "2º")+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(false &amp;&amp; true || \"1º\" || \"2º\")&lt;/span&gt; : &lt;span&gt;"+(false &amp;&amp; true || "1º" || "2º")+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(true &amp;&amp; null &amp;&amp; 6 &amp;&amp; 5)&lt;/span&gt; : &lt;span&gt;"+(true &amp;&amp; null &amp;&amp; 6 &amp;&amp; 5)+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(null &amp;&amp; true &amp;&amp; false &amp;&amp; false)&lt;/span&gt; : &lt;span&gt;"+(null &amp;&amp; true &amp;&amp; false &amp;&amp; false)+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(false &amp;&amp; true &amp;&amp; false &amp;&amp; false)&lt;/span&gt; : &lt;span&gt;"+(false &amp;&amp; true &amp;&amp; false &amp;&amp; false)+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(true &amp;&amp; 1 &amp;&amp; true &amp;&amp; 2)&lt;/span&gt; : &lt;span&gt;"+(true &amp;&amp; 1 &amp;&amp; true &amp;&amp; 2)+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(true &amp;&amp; \"1º\" &amp;&amp; true &amp;&amp; \"2º\")&lt;/span&gt; : &lt;span&gt;"+(true &amp;&amp; "1º" &amp;&amp; true &amp;&amp; "2º")+"&lt;/span&gt;&lt;br /&gt;");
          $("#datos").append("&lt;span style=\"font-weight:bold\"&gt;(true &amp;&amp; true &amp;&amp; \"1º\" &amp;&amp; \"2º\")&lt;/span&gt; : &lt;span&gt;"+(true &amp;&amp; true &amp;&amp; "1º" &amp;&amp; "2º")+"&lt;/span&gt;&lt;br /&gt;");
      });
  &lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;div id="datos"&gt;&lt;/div&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>Return to HTML:</p>
  
  <pre><code>(false || null || "1º" || "2º") : 1º
  (false &amp;&amp; null || false || "2º") : 2º
  (false &amp;&amp; true || "1º" || "2º") : 1º
  (true &amp;&amp; null &amp;&amp; 6 &amp;&amp; 5) : null
  (null &amp;&amp; true &amp;&amp; false &amp;&amp; false) : null
  (false &amp;&amp; true &amp;&amp; false &amp;&amp; false) : false
  (true &amp;&amp; 1 &amp;&amp; true &amp;&amp; 2) : 2
  (true &amp;&amp; "1º" &amp;&amp; true &amp;&amp; "2º") : 2º
  (true &amp;&amp; true &amp;&amp; "1º" &amp;&amp; "2º") : 2º
  </code></pre>
  
  <p>Thank you.</p>
  
  <p>-- EDIT for Comments</p>
  
  <p>I need to accomplish the following in C#:</p>
  
  <pre><code>string value1 = string.Empty;
  string value2 = "default value";
  
  // Request.Form["valueA"] and Request.Form["valueB"] may be null
  value1 = (Request.Form["valueA"] || Request.Form["valueB"] || value2);
  </code></pre>