#include <bits/stdc++.h>   using namespace std;   inline int getc() {     char ch = getchar();     while (ch !=  0  && ch !=  1 ) {       ch = getchar();     }     return ch -  0 ;   }   int main() {     int n;     scanf( %d , &n);     int cnt1 = 0, cnt2 = 0;     for (int i = 0; i < n; ++i) {       if (getc() == i % 2)         cnt1++;       else         cnt2++;     }     printf( %d n , min(cnt1, cnt2));     ;     ;     ;   }   