Esempio n. 1
0
            public void ShouldReturnCorrectResult()
            {
                var    problem = new Problem0003();
                object result  = problem.GetResult();

                result.Should().Be(6857);
            }
Esempio n. 2
0
        public void Problem0003Test()
        {
            var factors = Problem0003.Solution(600851475143);
            var res     = new StringBuilder(factors[0].ToString());

            if (factors.Length > 1)
            {
                for (int i = 1; i < factors.Length; i++)
                {
                    res.AppendFormat(", {0}", factors[i]);
                }
            }

            Trace.WriteLine(res);
        }