#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, t, u;
  cin >> s;
  cin >> t;
  u = "";
  for (int i = 0; i < s.length(); i++)
    if (t[i] > s[i]) {
      cout << -1;
      return 0;
    } else if (t[i] == s[i])
      u += "z";
    else
      u += t[i];
  cout << u;
  return 0;
}
