title: BMI calculator assignment. c#. What am i doing wrong?
body: <p>Hi I've just started college and I have an assignment in <code>c#</code> where I have to create a BMI calculator that can calculate BMI in both metric and imperial. I have created the code below which comes up with many errors but I don't know why. Any ideas?</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  using System.Linq;
  using System.Text;
  using System.Threading.Tasks;
  
  namespace BMI_CALCULATOR
  {
      class Program
      {
          static void Main(string[] args)
          {
              int weightPounds, WeightKilo, heightMeters, heightInches, Menu;
             double BMI;
  
  
  
              Console.WriteLine("1. Imperial");
              Console.WriteLine("2. Metric");
              Console.WriteLine("3. Exit);
              Console.WriteLine("press 1 for Imperial, 2 for metric or 3 to exit: ");
             Menu = Convert.ToInt32(Console.ReadLine());
  
              if (Menu == 1)
              {
              Console.Write("please enter your weight in pounds: ");
              weightPounds = Convert.ToInt32(Console.ReadLine());
  
  
              Console.Write("please enter your height in inches: ");
              heightInches = Convert.ToInt32(Console.ReadLine());
  
              BMI = weightPounds / Math.Pow (heightInches, 2);
  
                  if (BMI &lt; 18.5) 
                  {
              Console.WriteLine("your BMI is {0:C}" , BMI, "you are underweight");
                  }
  
               else if ((BMI &gt;= 18.5) &amp;&amp; (&lt;= 24.9)) 
                  { 
                      Console.WriteLine("your BMI is {0:C}" , BMI, "you are normal");
                  }
  
                  else if (BMI &gt; 24.9 )
                  {
                      Console.WriteLine("your BMI is {0:C}" , BMI, "you are overweight");
                  }
  
              }
  
  
              else if (Menu == 2)
              {
                    Console.Write("please enter your weight in pounds: ");
              weightPounds = Convert.ToInt32(Console.ReadLine());
  
  
              Console.Write("please enter your height in inches: ");
              heightInches = Convert.ToInt32(Console.ReadLine());
  
              BMI = WeightKilo / Math.Pow (heightMeters, 2);
  
               if (BMI &lt; 18.5)
              {
  
               {
                    Console.WriteLine("your BMI is {0:C}" , BMI, "you are underweight");
               }
  
                    else if ((BMI &gt;= 18.5) &amp;&amp; (&lt;= 24.9)) 
                  { 
                      Console.WriteLine("your BMI is {0:C}" , BMI, "you are normal");
                  }
  
  
                  else if (BMI &gt; 24.9 )
                  {
                      Console.WriteLine("your BMI is {0:C}" , BMI, "you are overweight");
                  }
              }
  
  
              else if (Menu == 3)
              {
                  Console.WriteLine ("end program");
  
              }
  
  
  
              }
  
  
          }
      }
  }
  </code></pre>