fun main(args: Array<String>) {
    abc076c()
}

private val unrestorable = "UNRESTORABLE"

fun abc076c() {
    val (sd, t) = (1..2).map { readLine()!! }

    if (sd.length < t.length) return println(unrestorable)
    if (sd.length == t.length) {
        return if (sd.withIndex().all { iv -> iv.value == '?' || iv.value == t[iv.index] }) {
            println(t)
        } else {
            println(unrestorable)
        }
    }

    val diff = sd.length - t.length

    val probablyStrings = mutableListOf<String>()
    for (i in diff downTo 0) {
        val sub = sd.substring(i until i + t.length)
        if (sub.withIndex().all { iv -> iv.value == '?' || iv.value == t[iv.index] }) {
            probablyStrings += sd.substring(0 until i).replace('?', 'a') +
                    t + sd.substring(i + t.length, sd.length).replace('?', 'a')
        }
    }

    val answer = if (probablyStrings.isEmpty()) unrestorable else probablyStrings.min()!!

    println(answer)
}
