예제 #1
0
        public void TestFibonacci9()
        {
            FibonacciCounter counter = new FibonacciCounter();
            int input = 9;

            Assert.AreEqual(55, counter.counter(input));
        }
예제 #2
0
        public void TestFibonacci7()
        {
            FibonacciCounter counter = new FibonacciCounter();
            int input = 7;

            Assert.AreEqual(21, counter.counter(input));
        }
예제 #3
0
        public void TestFibonacci8()
        {
            FibonacciCounter counter = new FibonacciCounter();
            int input = 8;

            Assert.AreEqual(34, counter.counter(input));
        }
예제 #4
0
        public void TestFibonacci6()
        {
            FibonacciCounter counter = new FibonacciCounter();
            int input = 6;

            Assert.AreEqual(13, counter.counter(input));
        }
예제 #5
0
        static void Main(string[] args)
        {
            int position = 0;

            foreach (int fib in FibonacciCounter.GetFibonacciValue(22))
            {
                position++;
                Console.WriteLine("{0}:{1}", position, fib);
            }
        }