Two String Masks

Time limit2sMemory limit128 MB

Problem

You are given two strings S1 and S2. Each string consists of zero or more uppercase English letters and exactly one asterisk (*).

Replace each asterisk with a string made only of uppercase English letters. The replacement may also be the empty string. The two resulting strings must be identical.

Print a shortest string that can be obtained this way. If no such string exists, print -1.

Input

The first line contains S1, and the second line contains S2.

Each string has length between 1 and 50, inclusive, and consists only of zero or more uppercase English letters and exactly one asterisk (*).

Output

Print a shortest string that satisfies the condition. If no such string exists, print -1.