#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  string x, y;
  cin >> x >> y;
  string z = "";
  int l = x.size();
  for (int i = 0; i < l; i++) {
    if (x[i] < y[i]) {
      cout << "-1"
           << "\n";
      return 0;
    }
    if (x[i] == y[i] && x[i] != 'z') z += (y[i] + 1);
    if (x[i] == y[i] && x[i] == 'z') z += 'z';
    if (x[i] > y[i]) z += y[i];
  }
  cout << z << "\n";
  return 0;
}
