#include <bits/stdc++.h>
using namespace std;
int main() {
  string x;
  cin >> x;
  string y;
  cin >> y;
  string z;
  int n = x.length();
  for (int i = 0; i < n; i++) {
    if (x[i] == y[i])
      z.push_back('z');
    else if (x[i] > y[i])
      z.push_back(y[i]);
    else {
      cout << -1;
      return 0;
    }
  }
  cout << z << endl;
}
