title: how do I print a number less than 1 but greater than 0?
body: <p>I am expressing the power method in a script, at one point I am trying to do a negative, which is 1 / final_answer</p>
  
  <p>the thing is it does not print things such as 2^-3 which is .125</p>
  
  <pre><code>using System;
  
  class MainClass
  {
  static void Main()
  {
      Console.Write ("Enter a base number: ");
      string str_x = Console.ReadLine ();
      double x = double.Parse (str_x);
  
      Console.Write ("Enter an exponent: ");
      string str_n = Console.ReadLine ();
      double n = double.Parse (str_n);
  
      double final = 1;
      int count = 1;
      while (count != n+1) {
          final = final * x;
          count++;
      }
      if (n &lt; 0)
          final = 1 / final;
  
  
      Console.WriteLine(final);
  }
  </code></pre>
  
  <p>}</p>