def  = 1.0e-15
def  = 1/

def generateAddends = {
    def addends = []
    def n = 0.0
    def fact = 1.0
    while (true) {
        fact *= (n < 2 ? 1.0: n) as double
        addends << 1.0/fact
        if (fact > ) break