var n = require('fs').readFileSync('/dev/stdin', 'utf8');
var s = require('fs').readFileSync('/dev/stdin', 'utf8');

var result = 0;
var length = 1;
var target = s[0];
for (var i = 1; i < n; i += length) {
    length = 1;
    for (var j = i; j < n; j++) {
        if (target === s[j]) length++;
    }
    result++;
}

console.log(result);