Sum of Factors I tried many times ...but get TLE . Please help me to solve this.......

To me question is not clear, if input is say 12 then ans should be 1+2+4+3+6+12=28 or 2+2+3 = 7 (only prime factors).

n=int(input()) l=[] for i in range(n): k=int(input()) l.append(k)

for s in l: c=0 for i in range(1,s+1): if(s%i==0): c=c+i print(c)

To me question is not clear, if input is say 12 then ans should be 1+2+4+3+6+12=28 or 2+2+3 = 7 (only prime factors).