n=int(input())
s=input()
a=[]
for i in range(n):
    if i==n-1:
        a.append(s[i])
        continue
    if s[i]!=s[i+1]:
        a.append(s[i])
print(len(a)) n=int(input()) n int(input()) int input() input s=input() s input() input a=[] a [] for i in range(n):
    if i==n-1:
        a.append(s[i])
        continue
    if s[i]!=s[i+1]:
        a.append(s[i]) i range(n) range n if i==n-1:
        a.append(s[i])
        continue
     i==n-1 i n-1 n 1 a.append(s[i]) a.append a append s[i] s i continue if s[i]!=s[i+1]:
        a.append(s[i]) s[i]!=s[i+1] s[i] s i s[i+1] s i+1 i 1 a.append(s[i]) a.append a append s[i] s i print(len(a)) print len(a) len a n=int(input()) int(input()) n a=[] [] a s=input() input() s
n=int(input())
s=input()
a=[]
for i in range(n):
    if i==n-1:
        a.append(s[i])
        continue
    if s[i]!=s[i+1]:
        a.append(s[i])
print(len(a))