My answer is that I think you should take them indoors and let them show you their private part, and then discuss why they were showing other kids.
The same way you stop touching anything else. make no physical contact.
I would tell their guardian(s) that they need to stop; but nicely tho
If you don't want the other person to touch you like that, tell him/her to stop. And if he/she doesn't stop, you have to tell an adult that someone is touching you in a way you don't like.
Stop thinking of thoughts that make you excited That got you the boner in the first place. If not then stop playing with your privates.
Stop touching it so it can heal.
Tell them Stop! and mean it
You can firmly but politely say, "Please stop touching me, it makes me uncomfortable." It's important to set clear boundaries and communicate your preferences assertively. If the behavior continues, don't hesitate to seek help or report it to someone in authority.
Ask them politely.
Do not have dissimilar metals touching the plumbing pipe. If it is copper pipe, do not have steel or tin or anything else other than bras or copper or plastic touching the pipe
dont sit on it all day and do some frickingexcersise
Punch them in the face
If you mean how to stop touching your "private parts" as little kids would say xD to stop touching yourself you have to do things to distract you from wanting to do that,such as sports find something your interested in like soccer or volleyball or do something fun with your family like swimming or playing card games. Touching yourself isn't a bad thing most people do it,we most often touch ourselves for sexual pleasure or because it feels good and we're exploring out body. if you do this and want to continue it remember do it in privacy in your bedroom with your door shut and remind family that when your door is shut they need to knock. What ever you use to help with this must be CLEAN! to prevent infection and another reminder for heath reasons when you are done wash your hands or whatever you used.