#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  scanf("%d", &n);
  char str[125];
  cin >> str;
  int count = 0;
  int i = 0;
  while (str[i] == '1' && str[i] != '\0') {
    count++;
    i++;
  }
  if (count < n) count++;
  cout << count;
  return 0;
}
