Example #1
0
        public void Ex41_TestNegative2()
        {
            bool found = Ex41.InString("The bras basah complex", "bRO");

            Debug.WriteLine("The bras basah complex, bRO");
            Assert.IsFalse(found);
        }
Example #2
0
        public void Ex41_TestPositive2()
        {
            bool found = Ex41.InString("The brown fox", "bRO");

            Debug.WriteLine("The brown fox, bRO");
            Assert.IsTrue(found);
        }
Example #3
0
        public void Ex41_TestNegative1()
        {
            bool found = Ex41.InString("T", "bRO");

            Debug.WriteLine("T, FOX");
            Assert.IsFalse(found);
        }
Example #4
0
        public void Ex41_TestOneChar()
        {
            bool found = Ex41.InString("The brown fox", "o");

            Debug.WriteLine("The brown fox, o");
            Assert.IsTrue(found);
        }
Example #5
0
 public void Test()
 {
     int[] array = { 2, 4, 6 };
     Assert.Equal(12, Ex41.iterativeSum(array));
     Assert.Equal(12, Ex41.recursiveSum(array));
 }