import java.util.Scanner;
         
        public class Main { //クラス名はMain
            public static void main(String[] args) {
                //コード
              Scanner sc = new Scanner(System.in);
              int n1 = sc.nextInt();
              String wordw = sc.nextLine();
              int cut1 = n1 / 2;
              String word = sc.nextLine();
              String wordc1 = word.substring(0, cut1);
              String wordc2 = word.substring(cut1, n1);
              
              //処理打ち切り
              if (n1 <= 1) {
            System.out.println("No");
            return;
          } 
              //判定
              if (wordc1.equals(wordc2)) {
                	//等しいとき
                System.out.println("Yes");
           	}
          	else {
              		//等しくないとき
            		System.out.println("No");;
         		}
          }
        }
/tmp/hf-datasets-cache/medium/datasets/42704881117311-config-parquet-and-info-qiankunmu-Project_CodeNet-896c9d36/hub/datasets--qiankunmu--Project_CodeNet_Python800_and_Java250/snapshots/c899fde44a77ba1cc14973ed3de064e4ff3aadc7/Project_CodeNet_Java250.tar.gz