from itertools import groupby
n = int(input())
s = input()

gr = groupby(s)
ans = 0
for key, value in gr:
    ans += 1

print(ans) from itertools import groupby n = int(input()) n int(input()) int input() input s = input() s input() input gr = groupby(s) gr groupby(s) groupby s ans = 0 ans 0 for key, value in gr:
    ans += 1 key value gr ans += 1 ans 1 print(ans) print ans gr = groupby(s) groupby(s) gr ans = 0 0 ans s = input() input() s ans += 1 1 ans n = int(input()) int(input()) n
from itertools import groupby
n = int(input())
s = input()

gr = groupby(s)
ans = 0
for key, value in gr:
    ans += 1

print(ans)