Your iPhone could freeze up at some point in your user experience. When something goes wrong with your iPhone, Apple recommends a restart, quitting a problem app and resetting the device, in that order.
Restart the iPhone by holding down the "Sleep/Wake" button located at the top right side of the phone. Slide the red slider that appears at the top of the screen to turn off the phone. Press the "Sleep/Wake" button again to restart the phone.
Tap a troublesome app icon. Hold down the "Home" key, which is located at the center of the phone under the display, to force quit the app. Hold the button for roughly six seconds, and it should close the application without a restart.
Perform a reset on the iPhone. Hold down the "Sleep/Wake" button and the "Home" button simultaneously for several seconds. Ignore the red slider when it appears. Continue to hold until the Apple logo disappears from the screen to reset the operating system and power off the device. Press and hold the "Sleep/Wake" button until the Apple logo appears on the screen to turn it back on.