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