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