if(len(
JOINARRAY(GREPARRAY(split(B1, ""), regexp(item, "[0-9]")), "")
)=1||
len(JOINARRAY(GREPARRAY(split(B1, ""), regexp(item, "[0-9]")), ""))=2
,JOINARRAY(GREPARRAY(split(B1, ""), regexp(item, "[0-9]")), "")+'P',
left(JOINARRAY(GREPARRAY(split(B1, ""), regexp(item, "[0-9]")), ""),2)+'P'
)
1587629885370343.cpt