It looks like you're new here. If you want to get involved, click one of these buttons!

Function:

```
math.sum = function(variable, from, to, condition)
local n = 0
for i = from, to do
print(variable, i)
local c = condition:gsub(variable, i)
print(c)
n = n + tonumber(c)
end
return n
end
```

In Main:

```
print(math.sum("n", 1, 35, "1/n^n"))
```

Error:

```
Math:8: attempt to perform arithmetic on a nil value
stack traceback:
Math:8: in function 'math.sum'
Main:8: in function 'setup'
```

## Comments

@TokOut Try this.

Thank you very much! That helped. I mean I tried loadscreen, too, but for some reason it didnâ€™t worked. Now I see how to use it, again.