#include <bits/stdc++.h>
using namespace std;
int main() {
  char x[101] = {0};
  char y[101] = {0};
  char z[101] = {0};
  scanf("%s", x);
  scanf("%s", y);
  const int n = strlen(x);
  for (int i = 0; i < n; i++) {
    if (x[i] < y[i]) {
      printf("-1\n");
      return 0;
    }
  }
  for (int i = 0; i < n; i++) {
    if (x[i] == y[i]) {
      if (x[i] == 'z')
        z[i] = 'z';
      else {
        z[i] = x[i] + 1;
      }
    } else if (x[i] > y[i]) {
      z[i] = y[i];
    }
  }
  for (int i = 0; i < n; i++) {
    printf("%c", z[i]);
  }
  printf("\n");
  return 0;
}
