How to make computations based on user input
<p>Here's my block of code, and I can't figure out how to make girth and volume perform the calculation. For example, when I input 1,1,1,1 for the first 4 parameters, I get 0, 0 for volume and girth.</p>

<pre><code>       if (packages == 1)
        {

            int width = 0, length = 0, height = 0, weight = 0;
            int volume = 0, girth = 0;
            int[] packageInfo = new int[6] { width, length, height, weight ,volume, girth };
            packageInfo[4] = height * width * length;
            packageInfo[5] = (2 * length + 2 * width);
            double packageSum = 0;


            for (int k = 0; k &lt; 4; k++)
            {
                string line = Console.ReadLine();
                if (!int.TryParse(line, out packageInfo[k]))
                {
                    Console.WriteLine("Couldn't parse {0} - please enter integers", line);
                    k--;
                }
            }

            if(packageInfo[3] &gt; 25)
            {
                packageSum = 0;
                Console.WriteLine("Package couldn't be shipped because of its size.");
            }
            if (volume &gt; 4800)
            {
                packageSum = packageSum + 5.95;
            }

            if (volume &gt; 9600)
            {
                packageSum = 0;
                Console.WriteLine("Package couldn't be shipped because of its size.");
            }

            foreach (var item in packageInfo)
                Console.WriteLine(item.ToString());

        }
</code></pre>
