#include <bits/stdc++.h>
using namespace std;
const int inf = 1e9 + 7;
const int N = 1e6;
int main() {
  ios_base::sync_with_stdio(0);
  int a, b, n, T, cas = 0;
  string s;
  cin >> T;
  while (T--) {
    cin >> n >> s;
    string res = "";
    for (int i = 0; i < n; ++i) {
      if ((s[i] - '0') % 2) res.push_back(s[i]);
      if (res.size() == 2) break;
    }
    if (res.size() == 2)
      cout << res << endl;
    else
      cout << -1 << endl;
  }
  return 0;
}
