#include <stdio.h>
#include <cmath>
#include <algorithm>
#include <cfloat>
#include <stack>
#include <queue>
#include <vector>
#include <string>
#include <iostream>
typedef long long int ll;
typedef unsigned long long int ull;
#define BIG_NUM 2000000000
#define MOD 1000000007
#define EPS 0.000000001
using namespace std;

int main() {

	int N;
	scanf("%d",&N);

	char* buf = new char[N+1];

	scanf("%s",buf);

	int ans = 0;

	char pre = '@';

	for(int i = 0; buf[i] != '\0'; i++){
		if(buf[i] == 'o'){
			ans++;
		}else if(buf[i] == 'x' && pre != 'x'){
			ans++;
		}else{
			break;
		}
		pre = buf[i];
	}

	printf("%d\n",ans);

	return 0;
}