#include <bits/stdc++.h>
using namespace std;
inline int read() {
  char ch = getchar();
  bool f = 1;
  int ans = 0;
  while (!isdigit(ch)) f ^= ch == '-', ch = getchar();
  while (isdigit(ch)) ans = (ans << 3) + (ans << 1) + (ch ^ 48), ch = getchar();
  return f ? ans : -ans;
}
const int maxn = 1e6 + 5;
char c[maxn], a[maxn];
int cnt[2][2];
int a1, a2, a3, a4, b1, b2, b3, b4;
int main() {
  int n;
  n = read();
  cin >> c >> a;
  for (int i = 0; i < n; ++i) cnt[c[i] - '0'][a[i] - '0']++;
  for (int a3 = 0; a3 <= cnt[1][0]; ++a3) {
    for (int a4 = 0; a4 <= cnt[1][1]; ++a4) {
      b4 = cnt[1][1] - a4;
      b2 = a3 + a4 - b4;
      if (b2 < 0 || b2 > cnt[0][1]) continue;
      a2 = cnt[0][1] - b2;
      a1 = n / 2 - a2 - a3 - a4;
      if (a1 < 0 || a1 > cnt[0][0]) continue;
      for (int i = 0; i < n; ++i) {
        if (a1 && c[i] == '0' && a[i] == '0') printf("%d ", i + 1), a1--;
        if (a2 && c[i] == '0' && a[i] == '1') printf("%d ", i + 1), a2--;
        if (a3 && c[i] == '1' && a[i] == '0') printf("%d ", i + 1), a3--;
        if (a4 && c[i] == '1' && a[i] == '1') printf("%d ", i + 1), a4--;
      }
      cout << endl;
      return 0;
    }
  }
  cout << -1 << endl;
  return 0;
}
