In one sentence, describe what the following article is about:

Then it will ask for a code. The code is 12345 (the default). Now you are finished, your phone will restart with all the phone memory formatted.

Summary:
You can remove the mmc but keep the sim card and restart your phone. Then press the keys *#7370#. The phone would ask a confirmation. Select yes.