function main(input){
    var tmp = input.split('\n');
    var n = perseInt(tmp[0]);
    var s = tmp[1];
    if(n%2==0){
        var t = s.slice(0,n/2-1);
        if(t[0]==t[1]){
            console.log("Yes");
        }else{
            console.log("No");
        }
    }else{
        console.log("No");
    }
}
main(require("fs").readFileSync("/dev/stdin", "utf8"));