Question #312718

Write a program to display the numbers 8 down to 0 underneath one another, making use of a loop


Expert's answer

using System;

namespace number8_0
{
    class Program
    {
        public static void Main(string[] args)
        {
            for (int i=8; i>=0; i--)
                Console.WriteLine("{0}", i);
            Console.WriteLine();
            Console.Write("Press any key to continue . . . ");
            Console.ReadKey(true);
        }
    }
}
LATEST TUTORIALS
APPROVED BY CLIENTS