Harryxun/stf_run huggingface dataset:
a = [int(input()) for x in range(5)]
sum = 0
b = []
for i in range(5):
    if a[i]%10 == 0:
        sum += a[i]
    else:
        c = a[i] + (10 -a[i]%10)
        sum += c
        b.append(a[i]%10)
b.sort()
sum -= 10 - b[0]
print(sum)

### FIXED CODE ###

a = [int(input()) for x in range(5)]
sum = 0
b = []
for i in range(5):
    if a[i]%10 == 0:
        sum += a[i]
    else:
        c = a[i] + (10 -a[i]%10)
        sum += c
        b.append(a[i]%10)
if b != []:
    b.sort()
    sum -= 10 - b[0]
print(sum)
# coding: utf-8
from collections import defaultdict, deque


def popcount(x):
    x -= (x >> 1) & 0x55555555
    x = (x & 0x33333333) + ((x >> 2) & 0x33333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f
    x += x >> 8
    x += x >> 16
    return x & 0x3f


def solve(*args: str) -> str:
    n = int(args[0])
    x = args[1]

    ret = []
    dp = defaultdict(int)
    x_count = x.count('1')
    x_dec = int(x, 2)

    x_mod_set = x_dec % (x_count+1)
    x_mod_reset = x_dec % (x_count-1)
    xor_set = 1 % (x_count+1)
    xor_reset = 1 % (x_count-1)
    for i in range(n):
        bitcount = x_count + (1 if x[-1-i] == '0' else -1)
        if bitcount == 0:
            ret.append(0)
            continue

        m = (x_mod_set + xor_set
             if x[-1-i] == '0' else
             x_mod_reset - xor_reset) % bitcount
        deq = deque([m])

        count = 1
        while m:
            deq.append(m)
            if 0 < dp[m]:
                count += dp[m]
                break

            m = m % popcount(m)
            count += 1

        ret.append(str(count))

        while deq:
            dp[deq.popleft()] = count
            count -= 1

        xor_set = (xor_set << 1) % (x_count+1)
        xor_reset = (xor_reset << 1) % (x_count-1)

    return '\n'.join(ret[::-1])


if __name__ == "__main__":
    print(solve(*(open(0).read().splitlines())))


### FIXED CODE ###

# coding: utf-8
from collections import defaultdict, deque


def popcount(x):
    assert x.bit_length() <= 32
    x -= (x >> 1) & 0x55555555
    x = (x & 0x33333333) + ((x >> 2) & 0x33333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f
    x += x >> 8
    x += x >> 16
    return x & 0x3f


def solve(*args: str) -> str:
    n = int(args[0])
    x = args[1]

    ret = []
    dp = defaultdict(int)
    x_count = x.count('1')
    x_dec = int(x, 2)

    x_mod_set = x_dec % (x_count+1)
    xor_set = 1 % (x_count+1)
    if 1 < x_count:
        x_mod_reset = x_dec % (x_count-1)
        xor_reset = 1 % (x_count-1)

    for i in range(n):
        bitcount = x_count + (1 if x[-1-i] == '0' else -1)
        if bitcount == 0:
            ret.append(str(0))
            continue

        m = (x_mod_set + xor_set
             if x[-1-i] == '0' else
             x_mod_reset - xor_reset) % bitcount
        deq = deque([m])

        count = 1
        while m:
            deq.append(m)
            if 0 < dp[m]:
                count += dp[m]
                break

            m = m % popcount(m)
            count += 1

        ret.append(str(count))

        while deq:
            dp[deq.popleft()] = count
            count -= 1

        xor_set = (xor_set << 1) % (x_count+1)
        if 1 < x_count:
            xor_reset = (xor_reset << 1) % (x_count-1)

    return '\n'.join(ret[::-1])


if __name__ == "__main__":
    print(solve(*(open(0).read().splitlines())))
N = int(input())
ans = 0
for i in range(1, N+1):
  if len(str(i)) % 2 == 1:
    ans += 1
print(ans)

### FIXED CODE ###

A, B, C = list(map(int, input().split()))
ans = B + C - A
if ans < 0:
  ans = 0
print(ans)
n,l,t=map(int,input().split())
a,cs=[0]*n,0
for i in range(n):
	x,y=map(int,input().split())
	x+=(t if y==1 else -t)
	cs=(cs+x//l)%n
	x%=l
	a[i]=x
a.sort()
print('\n'.join([str(a[(i+cs)%n]) fori in range(n)]))


### FIXED CODE ###


import sys
N, L, T = [int(x) for x in input().strip().split(" ")]

xys = []
candidates = []
for line in sys.stdin:
    x, y = line.strip().split(" ")
    x, y = int(x), int(y)
    xys.append((x,y))
    candidates.append((x + (1 if y == 1 else -1) * T)%L)

x0, y0 = xys[0]

dxs = []
pr_x = None
counter = 0
for x, y in xys[1:]:
    if y != y0:
        if pr_x == None:
            if y0 == 1:
                a = (x - x0)
        else:
            dxs.append(x - pr_x)
        pr_x = x
        counter += 1

if pr_x == None:
    for x in candidates:
        print(x)
    sys.exit()
if y0 == 2:
    a = (L - pr_x) + x0

ree = (2*T)%L
num_round = (2*T)//L
ree = ree - a
if ree <= 0:
    max_i = 0
else:
    for i, dx in enumerate(dxs if y0 == 1 else dxs[::-1]):
        ree = ree - dx
        if ree <= 0:
            max_i = i + 1
            break
    else:
        max_i = counter

if ree == 0 and y0 == 2:
    max_i += 1

c_n = num_round * counter + max_i

rep = ( 
        ((1 if y0 == 1 else -1) * (c_n % N) % N),
        ((x0 + (1 if y0 == 1 else -1) * (T % L)) % L)
        )


candidates = sorted(candidates)

for i, c in enumerate(candidates):
    if c == rep[1]:
        start = i - rep[0]
        break

for j in range(N):
    print(candidates[(start + j) % N])
N, K = map(int, input().split())
A = list(map(int, input().split()))
F = list(map(int, input().split()))

#Aを降順Fを昇順に並べる

li_f = list.sort(F)
li_a = list.sort(A, reverse=True)

#二つの要素同士をかける

from operator import mul
combined1 = map(mul, li_f, li_a)

#作業をK回繰り返す

for i in range(1, K):

#まずかけたやつのリストで最大のものが何番目なのかを取り出す

	n_max = combined1.index(max(combined1))

#それはli_aのインデックスと同じなのでそのインデックスのli_aの要素を取り出す
#その値から１引いて元に戻す

	li_a[n_max] = li_a[n_max] - 1
	ans = max(combined1)
    
print(ans)

### FIXED CODE ###

import numpy as np

import sys
input = sys.stdin.buffer.readline

N, K = map(int, input().split())
A = np.array(input().split(), np.int64)
F = np.array(input().split(), np.int64)

A.sort()
F.sort()

F= F[::-1]

left = -1
right = (A * F).sum()
while left + 1 < right:
  middle = (left + right) // 2
  right_arr = np.maximum(0, A - middle // F).sum() <= K
  if right_arr:
    right = middle
  else:
    left = middle
print(right)
class UnionFind():
    def __init__(self, n):
        self.parents = [-1]*n
        self.count = [1]*n
    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]
    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)
        if x == y:
            return
        self.parents[y] = x
        self.count[x] +=  self.count[y]

n,m,k = map(int,input().split())
uf = UnionFind(n)
block = [[] for i in range(n)]
for i in range(m):
    a,b = map(int,input().split())
    uf.union(a-1,b-1) 
    block[a-1].append(b-1)
    block[b-1].append(a-1)
for i in range(k):
    c,d = map(int,input().split())
    if uf.find(c-1) == uf.find(d-1):
        block[c-1].append(d-1)
        block[d-1].append(c-1)
ans = []
for i in range(n):
    ans.append(uf.count[uf.find(i)]-len(block[i])-1)
print(" ".join(map(str,ans)))

### FIXED CODE ###

import sys
sys.setrecursionlimit(100000)
class UnionFind():
    def __init__(self, n):
        self.parents = [-1]*n
        self.count = [1]*n
    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]
    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)
        if x == y:
            return
        self.parents[y] = x
        self.count[x] +=  self.count[y]
n,m,k = map(int,input().split())
uf = UnionFind(n)
block = [[] for i in range(n)]
for i in range(m):
    a,b = map(int,input().split())
    uf.union(a-1,b-1) 
    block[a-1].append(b-1)
    block[b-1].append(a-1)
for i in range(k):
    c,d = map(int,input().split())
    if uf.find(c-1) == uf.find(d-1):
        block[c-1].append(d-1)
        block[d-1].append(c-1)
ans = []
for i in range(n):
    ans.append(uf.count[uf.find(i)]-len(block[i])-1)
print(" ".join(map(str,ans)))
A,B = map(int,input().split())

import math

GCD = math.gcd(A,B)

def prime_factorize(n):
    a = []
    while n % 2 == 0:
        a.append(2)
        n //= 2
    f = 3
    while f * f <= n:
        if n % f == 0:
            a.append(f)
            n //= f
        else:
            f += 2
    if n != 1:
        a.append(n)
    return a

PF = prime_factorize(GCD)

PF = set(PF)

res = len(PF) + 1

print(res)


### FIXED CODE ###

A,B = map(int,input().split())

import fractions

GCD = fractions.gcd(A,B)

def prime_factorize(n):
    a = []
    while n % 2 == 0:
        a.append(2)
        n //= 2
    f = 3
    while f * f <= n:
        if n % f == 0:
            a.append(f)
            n //= f
        else:
            f += 2
    if n != 1:
        a.append(n)
    return a

PF = prime_factorize(GCD)

PF = set(PF)

res = len(PF) + 1

print(res)
N = int(input())
B = str(input())
B_array = np.array(list(map(int, list(B))))
B_1 = B_array.sum()
mod_list_m1 = []
mod_list = []
mod_list_p1 = []
for i in range(N):
    mod_list.append((2**i) % (B_1))
    mod_list_m1.append((2**i) % (B_1-1))
    mod_list_p1.append((2**i) % (B_1+1))
mod_list = np.array(mod_list)[::-1]
mod_list_m1 = np.array(mod_list_m1)[::-1]
mod_list_p1 = np.array(mod_list_p1)[::-1]

def calc_small(n, iter):
    
    iter += 1
    mod = n % np.array(list(map(int, list(bin(n)[2:])))).sum()
    if mod == 0:
        return iter
    else:
        return calc_small(mod, iter)

for i in range(N):
    Z_array = B_array.copy()
    Z_array[i] = 1 if B_array[i] == 0 else 0
    if Z_array.sum() == 0:
        print(1)
        continue
    mod = Z_array.dot(mod_list_p1) % (B_1+1) if B_array[i] == 0 else Z_array.dot(mod_list_m1) % (B_1-1)
    iter = 1
    if mod == 0:
        print(iter)
    else:
        print(calc_small(mod, iter))

### FIXED CODE ###

N = int(input())
B = input()

B_1 = B.count("1")
mod_p1 = int(B,2) % (B_1+1)
if B_1 != 1:
    mod_m1 = int(B,2) % (B_1-1)

def calc_small(n, iter):
    iter += 1
    mod = n % bin(n).count("1")

    if mod == 0:
        return iter
    else:
        return calc_small(mod, iter)

for i in range(N):
    if B_1 == 1 and int(B[i]) == 1:
        print(0)
        continue
    mod = (mod_m1 - pow(2,N-i-1,B_1-1)) % (B_1-1) if int(B[i]) == 1 else (mod_p1 + pow(2,N-i-1,B_1+1)) % (B_1+1)
    iter = 1
    if mod == 0:
        print(iter)
    else:
        print(calc_small(mod, iter))
i = {1,2,4,8,16,32,64,128}
k = int(input())

for p in range(len(i)):
  if k <= i[p]:
    print(i[p])
    break

### FIXED CODE ###

i = [1,2,4,8,16,32,64,128]
k = int(input())
 
for p in range(len(i)):
  if k == 1:
    print(1)
    break
  elif k < i[p]:
    print(i[p-1])
    break
n,k = map(int, input().split())
s = input()

if n == 1:
  print(0)
  exit()

two = 0
pre = s[0]
cont = 1
for c in s[1:]:
  if c != pre:
    if c == s[0]:
      two += 1
    ans += cont-1
    cont = 1
    pre = c
  else:
    cont += 1
ans += cont-1

if s[0] != s[1]:
  ans += 1
print(ans + 2*min(k,two))

### FIXED CODE ###

n, k = map(int, input().split())
s = input()

if n == 1:
    print(0)
    exit()

two = 0
pre = s[0]
cont = 1
ans = 0
for c in s[1:]:
    if c != pre:
        if c == s[0]:
            two += 1
        ans += cont - 1
        cont = 1
        pre = c
    else:
        cont += 1
ans += cont - 1

if s[0] != s[-1] and k > two:
    ans += 1
print(ans + 2 * min(k, two))
from math import sqrt
def divisors(n):
    divisors = []
    for i in range(1, int(sqrt(n))+1):
        q, r = divmod(n, i)
        if r == 0:
            divisors.append(i)
            if i != q:
                divisors.append(q)
    return divisors

n, p = map(int, input().split())
x = 1
for k, v in factorint(p).items():
    x *= k ** (v//n)
print(x)

### FIXED CODE ###

from math import sqrt
def factorint(n):
    d = {}
    for i in range(2, int(sqrt(n))+1):
        c = 0
        q, r = divmod(n, i)
        while not r:
            c += 1
            n = q
            q, r = divmod(n, i)
        if c:
            d[i] = c
    if n != 1:
        d[n] = 1
    return d

n, p = map(int, input().split())
x = 1
for k, v in factorint(p).items():
    x *= k ** (v//n)
print(x)
N,A,B,C=map(int,input().split())
S = [input() for _ in range(N)]
table = [A,B,C]
ans = []

def ci(s):
    if s == 'AB':
        return 0,1
    elif s == 'BC':
        return 1,2
    else:
        return 0,2

if A+B+C == 0:
    print('No')
elif A+B+C == 1:
    for s in S:
        i,j = ci(s)
        if table[i] == 0 and table[j] == 0:
            print('No')
            exit()
        else:
            if table[i] == 0:
                table[i] = 1
                table[j] = 0
                ans.append(i)
            else:
                table[j] = 1
                table[i] = 0
                ans.append(j)

else:
    for k in range(N):
        i,j= ci(S[k])
        if table[i] > table[j]:
            i,j = j,i
        # print(table,i,j)
        if k + 1 < N:
            i2,j2 = ci(S[k+1])
        if table[i] == 0 and table[j] == 0:
            print('No')
            exit()
        elif table[i] == 0 and table[j] > 0:
            table[i] += 1
            table[j] -= 1
            ans.append(i)
        else:
            table[i] += 1
            table[j] -= 1
            if table[i2] == 0 and table[j2] == 0:
                table[i] -= 2
                table[j] += 2
                ans.append(j)
            else:
                ans.append(i)

print('Yes')
L = ['A','B','C']
for a in ans:
    print(L[a])

### FIXED CODE ###

N,A,B,C=map(int,input().split())
S = [input() for _ in range(N)]
table = [A,B,C]
ans = []

def ci(s):
    if s == 'AB':
        return 0,1
    elif s == 'BC':
        return 1,2
    else:
        return 0,2

if A+B+C == 0:
    print('No')
    exit()
elif A+B+C == 1:
    for s in S:
        i,j = ci(s)
        if table[i] == 0 and table[j] == 0:
            print('No')
            exit()
        else:
            if table[i] == 0:
                table[i] = 1
                table[j] = 0
                ans.append(i)
            else:
                table[j] = 1
                table[i] = 0
                ans.append(j)

else:
    for k in range(N):
        i,j= ci(S[k])
        if table[i] > table[j]:
            i,j = j,i
        # print(table,i,j)
        if k + 1 < N:
            i2,j2 = ci(S[k+1])
        if table[i] == 0 and table[j] == 0:
            print('No')
            exit()
        elif table[i] == 0 and table[j] > 0:
            table[i] += 1
            table[j] -= 1
            ans.append(i)
        else:
            table[i] += 1
            table[j] -= 1
            if k + 1 < N:
                if table[i2] == 0 and table[j2] == 0:
                    table[i] -= 2
                    table[j] += 2
                    ans.append(j)
                else:
                    ans.append(i)
            else:
                ans.append(i)

print('Yes')
L = ['A','B','C']
for a in ans:
    print(L[a])
N = int(input())
A = [int(input()) for i in range(N)]
for i in A:
    if A.count(i) >= 1:
        if A.count(i)%2 == 0: 
            A.remove(i)   
print(B)

### FIXED CODE ###

N = int(input())
list = set()
for i in range(N):
    i = int(input())
    if i not in list:
        list.add(i)
    elif i in list:
        list.remove(i)
print(len(list))
n, a, b = map(int, input().split())

def digitSum(n):
    s = str(n)
    array = list(map(int, list(s)))
    return sum(array)
  
sum = 0
for i in range(n+1):
  c = digitSum(i)
  if a <= c and c <= b: sum += i
    
print(sum)

### FIXED CODE ###

n, a, b = map(int, input().split())

def digitSum(n):
    return sum(list(map(int, list(str(n)))))
  
s = 0
for i in range(n+1):
  c = digitSum(i)
  if a <= c and c <= b: s += i
    
print(s)
import math
def lcm(x, y):
    return int((x * y) / math.gcd(x, y))
  

A, B = map(int, input().split())
print(lcm(A, B))

### FIXED CODE ###

from fractions import gcd

A, B = map(int, input().split())

print(A * B // gcd(A, B))
import sys
sys.setrecursionlimit(1000)

n=int(input())
h=list(map(int,input().split()))
dp=[float('inf')]*n
dp[0]=0
 
def rec(i):
    if dp[i]<float('inf'):
        return dp[i]
    
    if i==0:
        return 0
    
    res=float('inf')#最小に更新する
    
    res=min(res,rec(i-1)+abs(h[i]-h[i-1]))
    if i>1:
        #i-2が負になる場合を避ける
        res=min(res,rec(i-2)+abs(h[i]-h[i-2]))
    
    return res
    
    
print(rec(n-1))

### FIXED CODE ###

n=int(input())
h=list(map(int,input().split()))

dp=[float('inf')]*n
dp[0]=0#初期条件を設定

for i in range(1,n):
    dp[i]=min(dp[i],dp[i-1]+abs(h[i]-h[i-1]))
    #i=1の時i-2<0となるので先にここを計算する
    if i>=2:
        dp[i]=min(dp[i],dp[i-2]+abs(h[i]-h[i-2]))
        
print(dp[-1])
s=list(input())
al=[chr(ord('a') + i) for i in range(26)]
al=[i for i in al if i not in s]
if al:
    print(''.join(s)+al[0])
    exit()
for i in range(25,0,-1):
    if s[i-1]<s[i]:
        a=[j for j in s[i:] if s[i]>j]
        s=s[:i-1]+[sorted(a)[0]]
        print(''.join(s))
        exit()
else:print(-1)

### FIXED CODE ###

s=list(input())
al=[chr(ord('a') + i) for i in range(26)]
al=[i for i in al if i not in s]
if al:
    print(''.join(s)+al[0])
    exit()
for i in range(25,0,-1):
    if s[i-1]<s[i]:
        a=[j for j in s[i-1:] if s[i-1]<j]
        s=s[:i-1]+[sorted(a)[0]]
        print(''.join(s))
        break
        exit()
else:print(-1)
import math

N = int(input())
if N%2 == 1:
  print(0)
  exit()
five = N//10
for i in range(int(math.log(N//10,5))):
  five += N//(10*5**(i+1))
print(five)
124999999999999995

### FIXED CODE ###

import math

N = int(input())
if N%2 == 1 or N<10:
  print(0)
  exit()
five = N//10
for i in range(int(math.log(N//10,5))):
  five += N//(10*5**(i+1))
print(five)
s = list(input())
a = []

for i in s:
  if i == "0" or i == "1" :
    a += [i]
  elif: a != []
    del a[-1]

print(a)

### FIXED CODE ###

s = list(input())
a = []

for i in s:
  if i == "0" or i == "1" :
    a += [i]
  elif a != []:
    del a[-1]

print("".join(a))
from collections import defaultdict as dd
primes = dd(int)
n,p = int(input().split())
gcd = 1
for i in range(2,int(p**0.5)+1):
  while p%i == 0:
    p //= i
    primes[i] += 1
for fac in primes:
  gcd *= fac**(primes[fac]//n)
print(gcd)

### FIXED CODE ###

from collections import defaultdict as dd
primes = dd(int)
n,p = map(int, input().split())
gcd = 1
for i in range(2,int(p**.5)+1):
  while p%i == 0:
    p //= i
    primes[i] += 1
if p > 1:
  primes[p] += 1
for fac in primes:
  gcd *= fac**(primes[fac]//n)
print(gcd)
i,j,n=map(int,input().split())
i_num=i/n
j_num=j/n
cnt=j_num-i_num
if i_num % j==0:
  cnt+=1
print(cnt)

### FIXED CODE ###

a,b,c=map(int,input().split())
print(int((b//c)-(a-1)//c))
a b=int(input().split())
if a < 10:
  print(b)
else:
  print(b-1000+100*a)


### FIXED CODE ###

a,b=map(int,input().split())

if a >=10:
  c=int(b)
  print(c)
else:
  c=int(b+1000-100*a)
  print(c)
import numpy as np
A, B = map(int, input().split())

pre = A
for b in np.arange(A+1, B+1):
    pre = pre ^ b
print(pre)

### FIXED CODE ###

import numpy as np

def f(x):
    fm = x - (x % 4) - 1 
    ans = 0
    while fm < x:
        fm += 1
        ans ^= fm
    return ans

A,B = map(int, input().split())
print(f(A-1) ^ f(B))
####
N = int(input())
A =  list(map(int,input().split()))

ans2 = 0
###
for y in range(N):
  for x in range(y+1,N):
    ans2 += (A[y] ^ A[x]) % 1000000007  
print(ans2%1000000007)
###


### FIXED CODE ###

A1, A2, A3 = map(int, input().split())

if (A1+A2+A3) <= 21:
  print('win') 
elif(A1+A2+A3) > 21:
  print('bust')
#!usr/bin/env python3

import sys


def main():
    # s: spades
    # h: hearts
    # c: clubs
    # d: diamonds
    card_deck = {'S': [], 'H': [], 'C': [], 'D': []}
    card_symbols = ['S', 'H', 'C', 'D']

    lst = [card for card in sys.stdin.readline().split()]
    card_deck[lst[0]].append(lst[1])

    for key, value in card_deck.items():
        card_deck[key].sort()

    for i in card_symbols:
        for card in range(1, 13):
            if not str(card) in card_deck[i]:
                print(i, card)


if __name__ == '__main__':
    main()

### FIXED CODE ###

#!usr/bin/env python3

import sys


def init_card_deck():
    # S: spades
    # H: hearts
    # C: clubs
    # D: diamonds
    card_deck = {'S': [], 'H': [], 'C': [], 'D': []}
    n = int(sys.stdin.readline())

    for i in range(n):
        lst = [card for card in sys.stdin.readline().split()]
        card_deck[lst[0]].append(lst[1])

    return card_deck


def print_missing_cards(card_deck):
    card_symbols = ['S', 'H', 'C', 'D']

    for i in card_symbols:
        for card in range(1, 14):
            if not str(card) in card_deck[i]:
                print(i, card)


def main():
    print_missing_cards(init_card_deck())


if __name__ == '__main__':
    main()
for i=0;i<9;i++
 for j=0;j<9;j++;j++
  print(i+1,"x",j+1"=",(i+1)*(j+1)),
 print("")


### FIXED CODE ###

for i in range(1,10):
	for j in range(1,10):
		print(i,"x",j,"=",i*j,sep="")
S, W = map(int,input.split())
if S <= W:
  print("unsafe")
else:print("safe")

### FIXED CODE ###

S, W = map(int,input().split())
if S <= W:
  print("unsafe")
else:print("safe")
nums = sorted(list(map(int, input().split())))
ans = 0
while nums[0] != nums[-1]:
  if nums[-1] - nums[0] >= 2:
    nums[0] += 2
  else:
    nums[0] += 1
    nums[1] += 1
  nums = sorted(nums)
  ans += 1
print(ans)

### FIXED CODE ###

S = input()
print('Yes' if all([True if S.count(s)==1 else False for s in 'abc']) else 'No')
Sp = input()
T = input()

if len(T) > len(Sp):
	print("UNRESTORABLE")
	exit()
	
oklist = []
for i in range(len(Sp) - len(T), -1,Sp = input()
T = input()

if len(T) > len(Sp):
	print("UNRESTORABLE")
	exit()
	
oklist = []
for i in range(len(Sp) - len(T), -1, -1):
	for j in range(len(T)):
		if Sp[i + j] != "?" and Sp[i + j] != T[j]:
			break
	else:
		okpre = ["a" if Sp[k] == "?" else Sp[k] for k in range(i)]
		oksuf = ["a" if Sp[k] == "?" else Sp[k] for k in range(i + len(T), len(Sp))] 
		oklist.append("".join(okpre) + T + "".join(oksuf))

if oklist:
	print(min(oklist))
else:
	print("UNRESTORABLE") -1):
	for j in range(len(T)):
		if Sp[i + j] != "?" and Sp[i + j] != T[j]:
			break
	else:
		print(i)
		okpre = ["a" if Sp[k] == "?" else Sp[k] for k in range(i)]
		oksuf = ["a" if Sp[k] == "?" else Sp[k] for k in range(i + len(T), len(Sp))] 
		oklist.append("".join(okpre) + T + "".join(oksuf))

if oklist:
	print(min(oklist))
else:
	print("UNRESTORABLE")

### FIXED CODE ###

Sp = input()
T = input()

if len(T) > len(Sp):
	print("UNRESTORABLE")
	exit()
	
oklist = []
for i in range(len(Sp) - len(T), -1, -1):
	for j in range(len(T)):
		if Sp[i + j] != "?" and Sp[i + j] != T[j]:
			break
	else:
		okpre = ["a" if Sp[k] == "?" else Sp[k] for k in range(i)]
		oksuf = ["a" if Sp[k] == "?" else Sp[k] for k in range(i + len(T), len(Sp))] 
		oklist.append("".join(okpre) + T + "".join(oksuf))

if oklist:
	print(min(oklist))
else:
	print("UNRESTORABLE")
print "Yes" if (a + b + c) % 2 == 0 else "No"


### FIXED CODE ###

a, b, c = map(int, raw_input().split())
print "Yes" if (a + b + c) % 2 == 0 and (a + b + c) // 2 in [a, b, c] else "No"
h, w = (int(i) for i in input().split(' '))


a=[]
for i in range(h):
    a.append([int(j) for j in input().split(' ')])

j = 0
p = []
tr = []
picked = False

for i in range(h):
                
    step = -1 if i%2 else 1
    j = w-1 if i%2 else 0
    while j >=0 and j < w:
        if a[i][j] % 2:
            if picked == False:
                picked = True
            else:
                tr.append([i,j])
                picked = False
                for t_index in range(len(tr)-1):
                    p.append((tr[t_index], tr[t_index+1]))
                tr = []

        if picked:
            tr.append([i,j])
        j = j + step

print(len(p))
for ans in p:
    print(ans[0][0]+1,ans[0][1]+1,ans[1][0]+1, ans[1][1]+1)


### FIXED CODE ###

a, b = (int(i) for i in input().split(' '))
if (a*b) % 2:
    print('Yes')
else:
    print('No')