recently i saw a proof of the statement: "P is not closed under Pref operator" in short, we defined L={<M,w>#y : M(w) accepts and y is an accepting run of M(w) } it is easy to give a polynomial algorithm that checks the conditions. so, we get contradiction since P is in R and Pref(L) contains A_TM which isn’t decidable

my question is: how do i proof that NP is not close under Pref ??