iPhone runs on iOS which is very restrictive and runs all apps in sandboxed mode. Also Apple has a stringent review policy for approving applications in the App Store. Believe me, each and every app in the iTunes app store has been manually verified by Apple. read more
If the iPhone continues to hang up when you turn it on, the phone can be fixed by entering recovery mode, or DFU mode, and performing a restore. Restoring an iPhone clears all of the saved data and apps on the device. read more