# 問題：https://atcoder.jp/contests/abc143/tasks/abc143_c

n = int(input())
slimes = input()
res = 1
for i in range(1, n):
    if slimes[i-1] != slimes[i]:
        res += 1
print(res) n = int(input()) n int(input()) int input() input slimes = input() slimes input() input res = 1 res 1 for i in range(1, n):
    if slimes[i-1] != slimes[i]:
        res += 1 i range(1, n) range 1 n if slimes[i-1] != slimes[i]:
        res += 1 slimes[i-1] != slimes[i] slimes[i-1] slimes i-1 i 1 slimes[i] slimes i res += 1 res 1 print(res) print res n = int(input()) int(input()) n res += 1 1 res res = 1 1 res slimes = input() input() slimes
# 問題：https://atcoder.jp/contests/abc143/tasks/abc143_c

n = int(input())
slimes = input()
res = 1
for i in range(1, n):
    if slimes[i-1] != slimes[i]:
        res += 1
print(res)
