#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    string s, s2;
    int n;
    cin >> n >> s;
    for (int i = 0; i < s.size(); i++) {
      if (s2.size() == 2) break;
      if (int(s[i]) % 2 == 1) s2 += s[i];
    }
    if (s2.size() < 2)
      cout << -1;
    else
      cout << s2;
    cout << endl;
  }
}
