コード例 #1
0
        public void TestSolveHasSolution()
        {
            int result = new CookiesProblem().Solve(7, new int[] { 1, 2, 3, 9, 10, 12 });

            Assert.AreEqual(2, result);
        }
コード例 #2
0
        public void TestSolveHasNoSolution()
        {
            int result = new CookiesProblem().Solve(10, new int[] { 1, 1, 1, 1 });

            Assert.AreEqual(-1, result);
        }