fun main(args: Array<String>) {
    val S = readLine()!!
    val T = readLine()!!


    val candidates = mutableListOf<String>()
    (0..((S.length - 1) - (T.length - 1))).forEach {startIndex ->
        val replaced = S.replaceRange(startIndex, startIndex + T.length, T).replace("?", "a")
        // Check if it keeps original form
        var keepsOriginalForm = true
        S.forEachIndexed { index, c ->
            if (c != '?') {
                if (S[index] != replaced[index]) {
                    keepsOriginalForm = keepsOriginalForm && false
                }
            }
        }
        if (keepsOriginalForm) {
            candidates.add(replaced)
        }
    }
    candidates.sort()

    if (candidates.size > 0) {
        println(candidates[0])
    } else {
        println("UNRESTORABLE")
    }
}
