#include <bits/stdc++.h>
using namespace std;
int main() {
  string s1, s2, ans = "";
  cin >> s1 >> s2;
  for (int i = 0; i < s1.size(); ++i) {
    if (s1[i] == s2[i]) {
      ans += "z";
    } else if (s1[i] > s2[i]) {
      ans += s2[i];
    } else if (s1[i] < s2[i]) {
      puts("-1");
      return 0;
    }
  }
  cout << ans << endl;
  return 0;
}
