def numPF(n):
    maxNum=int(n**(1/2))
    count=0
    divisor=2
    while divisor<=maxNum and n>1:
        #print(n%divisor)
        if  n%divisor==0:
            while n%divisor ==0: n=n/divisor
            count+=1
        divisor+=1
    if n>1: count+=1
    return count

def change_left(num,p_index,p):
    for u in range(-p_index-1,-len(num)-1,-1):
        num[u]=int(num[u])+p
    num=list(map(str,num))
    return num

def change_right(num,p_index,p):
    if p_index>1:
            
            j=len(num)-p_index+1
            #print(len(num))
            #print("j",j)
            while len(num)-p_index+1<=j and j