import std.stdio, std.conv, std.string, std.range, std.algorithm, std.array,
  std.functional, std.container, std.typecons;

void main() {
  int N = readln.chomp.to!int;
  string S = readln.chomp;

  int ans = 0;
  char prev = '0';
  foreach(c; S) {
    if(c != prev) ans++;
    prev = c;
  }
  ans.writeln;
}
