Idea here is keep track of the first letter in the sequence and count consecutive occurances. Once you encounter a new letter you add the previous count and letter to the chain. Repeat n-1 times (since we seeded the initial '1' case). We always update temp after the inner loop since we will never have already added the last sequence.

```
def countAndSay(self, n):
s = '1'
for _ in range(n-1):
let, temp, count = s[0], '', 0
for l in s:
if let == l:
count += 1
else:
temp += str(count)+let
let = l
count = 1
temp += str(count)+let
s = temp
return s
```