#include <bits/stdc++.h>   using namespace std;   const int siz = 1000000 + 10;   char a[siz];   int main() {     int t, n, m = 0, i, l, k;     scanf( %d , &t);     scanf( %s , a);     int len = strlen(a);     int z = 0, o = 0;     for (l = 0; l < len; l++) {       if (a[l] ==  1 )         o++;       else if (a[l] ==  0 )         z++;     }     m = min(o, z);     len -= (2 * m);     printf( %d , len);     return 0;   }   