#include <bits/stdc++.h>
using namespace std;
int dx[4] = {-1, 1, 0, 0}, dy[4] = {0, 0, -1, 1};
char dc[4] = {'N', 'S', 'W', 'E'};
vector<int> v[200005];
int vis[200005], vis1[200005], vv[200005];
void bfs(int s) {
  queue<int> q;
  q.push(s);
  vis[s] = 0;
  while (!q.empty()) {
    int x = q.front();
    q.pop();
    for (int i = 0; i < v[x].size(); i++) {
      if (vis[v[x][i]] > vis[x] + 1) {
        vis[v[x][i]] = vis[x] + 1;
        q.push(v[x][i]);
      }
    }
  }
}
void bfs1(int t) {
  queue<int> q;
  q.push(t);
  vis1[t] = 1;
  vv[vis[t]]++;
  while (!q.empty()) {
    int x = q.front();
    q.pop();
    for (int i = 0; i < v[x].size(); i++) {
      if (vis[v[x][i]] == vis[x] - 1 && vis1[v[x][i]] == 0) {
        vv[vis[v[x][i]]]++;
        vis1[v[x][i]] = 1;
        q.push(v[x][i]);
      }
    }
  }
}
int main() {
  int n, ans;
  string s, curr, p;
  cin >> n;
  cin >> s;
  ans = n;
  curr = "";
  for (int i = 0; i < n; i++) {
    curr += s[i];
    p = s.substr(i + 1, i + 1);
    if (curr == p) {
      ans = min(ans, n - i);
    }
  }
  cout << ans << endl;
}
