You can also reset the Nokia Lumia 520 by:
1. Power off your phone preferably by removing the battery and re-installing it again
2. Press and hold the Volume Down button and connect your charger or USB cable (while the Volume Down button is held down) - in about 8 seconds, you should get and exclamation mark (!). After getting this exclamation mark, quickly press the following keys in order
Volume Up button
Volume Down button
Power button
Volume Down button
The process then begins with gears displayed on the screen. All completes in about 15 to 20 minutes.