At the top of every forum is a sticky post named
How to use this forum - please read.
It is very helpful for new forum members. You should read through it.
It talks about how to post code using the code tags to make it easier for us to help you. After you do, see if you can edit your reply#2 using code tags as covered in the sticky post.
You have code that does something.
You want to add newping to it.
What have you tried? Have you looked at any newping examples or tutorials? Have you tried adding it to your sketch? How did that go?