Zombie process

Hi

I need help because I don't know if it is possible to add a find inside a cat.

like I have a file with the pid of the process that use to became zombie. And I have the same pid stored in the var (pid1)

now, I have no clue how to check if the the find finds the pid or even if it's possible

Any help please

This should work:

while read pid
do
   pgrep $pid && pkill $pid
done < /home/ruben/Desktop/zombie.txt 

well thanks for trying but I found another solution and now I don't have zombies.

But I still have a problem and I fell like I'm very close to finish this bloddy script

What is wrong in this until cicle? Is it something clearly wrong??