title: C# Pass user input to method, and output result (from the main)?
body: <p>fairly new so please forgive the question.  I've written a method to take a string, covert it to a number, and return a Factorial of that number.  That works fine.  Its calling the method and printing the result that is confusing me.  Here is the code:</p>
  
  <pre><code>static void Main(string[] args)
  {
      Console.WriteLine("Type number to do factorial on..");
      var calc = Fact(Console.ReadLine());
      Console.WriteLine("The answer is " + calc);
  }
  
  private static string Fact(string numFact)
  {
      var number = 1;
      int factorial = Convert.ToInt32(numFact);
      for (int i = 1; i&lt;= factorial; i++)
      {
          number *= i;
      }
     // Console.WriteLine(number); added to test it works
      return numFact;
  }
  </code></pre>
  
  <p>Can somebody help please?  As you'll probably guess from looking, If I input 5, I get 5 returned.</p>