#include <bits/stdc++.h>
using namespace std;
const int N = 5005;
char a[N], b[N];
set<int> ca[4], cb[4];
bool f[N];
void sswap(int ai, int bi) {
  f[*ca[ai].begin()] = 0, f[*cb[bi].begin()] = 1;
  ca[bi].insert(*cb[bi].begin()), cb[ai].insert(*ca[ai].begin());
  ca[ai].erase(ca[ai].begin()), cb[bi].erase(cb[bi].begin());
}
int main() {
  int n;
  scanf("%d", &n);
  scanf("%s%s", a + 1, b + 1);
  int na = 0, nb = 0;
  for (int i = 1; i <= n / 2; ++i)
    ca[(a[i] - '0') * 2 + b[i] - '0'].insert(i), na += (a[i] == '1'), f[i] = 1;
  for (int i = n / 2 + 1; i <= n; ++i)
    cb[(a[i] - '0') * 2 + b[i] - '0'].insert(i), nb += (b[i] == '1');
  while (na > nb) {
    int t = na - nb;
    if (na - nb >= 2 && !ca[3].empty() && !cb[0].empty())
      sswap(3, 0), --na, ++nb;
    if (na - nb >= 1 && !ca[2].empty() && !cb[0].empty()) sswap(2, 0), --na;
    if (na - nb >= 1 && !ca[1].empty() && !cb[0].empty()) sswap(1, 0), ++nb;
    if (na - nb >= 1 && !ca[3].empty() && !cb[2].empty()) sswap(3, 2), ++nb;
    if (t == na - nb) break;
  }
  while (na < nb) {
    int t = na - nb;
    if (nb - na >= 2 && !ca[0].empty() && !cb[3].empty())
      sswap(0, 3), ++na, --nb;
    if (nb - na >= 1 && !ca[0].empty() && !cb[2].empty()) sswap(0, 2), ++na;
    if (nb - na >= 1 && !ca[0].empty() && !cb[1].empty()) sswap(0, 1), --nb;
    if (nb - na >= 1 && !ca[1].empty() && !cb[3].empty()) sswap(1, 3), ++na;
    if (t == na - nb) break;
  }
  if (na != nb)
    puts("-1");
  else
    for (int i = 1; i <= n; ++i)
      if (f[i]) printf("%d ", i);
  return 0;
}
