The application "Remote Turn Off" was really built with security in mind. When turned on simply texting "power#off" to the device from any number will force the device to shut down. Lets just say you accidentally left the phone at work and you didn't want your coworkers to just be able to pick up your phone and start snooping around. You could text the phone to shut down and they would have to go out of their way to turn on the phone to do said snooping.
Now for the fun part. If your buddy left his phone sitting around you could install this app and mess with him a bit by turning it off remotely. This may not be as practical for pranking use since it does require the phone to be rooted to work. Also you will want to power the phone off once by sending the text message since it will ask for root permissions the first time the sms is sent. However if the phone is rooted and you install it they will have no clue it is there since it runs in the background and there is no app icon. Grab the app from the source link below to torment your friends!
Via XDA