Esempio n. 1
0
 def testEuler20(self):
     self.assertEquals(p16.euler16(math.factorial(10)), 27)
Esempio n. 2
0
#!/usr/bin/env python

import unittest
import p16
import math


class Test(unittest.TestCase):
    def testEuler20(self):
        self.assertEquals(p16.euler16(math.factorial(10)), 27)


if __name__ == "__main__":
    unittest.main(exit=False)

    print "Problem 20: The sum of the digits in the number 100! is", p16.euler16(math.factorial(100))