I have this small snippet of code here;
for i=1,1000 do
n=math.floor(math.sin(i/10.0)*40)
s=''
for j=1,n do s=s+'-' end
print(s)
end
But it gives me an error on line 2: "attempt to perform arithmetic on global 's' (a string value)" I don't know why it's doing this, and it's driving me mad.
string.repinstead of the inner for.