n=int(input())
s = input()
a = s[0]
cnt = 1
for i in range(n):
    if a == s[i]:
        continue
    else:
        a = s[i]
        cnt += 1
    
print(cnt) n=int(input()) n int(input()) int input() input s = input() s input() input a = s[0] a s[0] s 0 cnt = 1 cnt 1 for i in range(n):
    if a == s[i]:
        continue
    else:
        a = s[i]
        cnt += 1
     i range(n) range n if a == s[i]:
        continue
    else:
        a = s[i]
        cnt += 1
     a == s[i] a s[i] s i continue a = s[i] a s[i] s i cnt += 1 cnt 1 print(cnt) print cnt cnt = 1 1 cnt n=int(input()) int(input()) n a = s[i] s[i] a cnt += 1 1 cnt s = input() input() s a = s[0] s[0] a
n=int(input())
s = input()
a = s[0]
cnt = 1
for i in range(n):
    if a == s[i]:
        continue
    else:
        a = s[i]
        cnt += 1
    
print(cnt)