title: Using params with ref keyword in C#
body: <p>I want to pass a variable number of arguments to a function so I used <code>params</code> keyword, but I also want to pass those arguments as reference. I tried by adding the <code>ref</code> keyword but Visual Studio shows </p>
  
  <blockquote>
    <p>The params parameter can not be declared as ref or out. </p>
  </blockquote>
  
  <p>Is it possible to send a variable number of arguments as reference? If not, then why?</p>
  
  <pre><code>public bool fbRemoveLastSeparator(params ref string[] sInputStrings)
  {
      try
      {
          foreach(string str in sInputStrings)
          {
              //do something
          }
          return true;
      }
      catch (Exception ex)
      {                
          return false;
      }
  }
  </code></pre>