Facebook claims that it is not possible to check all who have viewed or visited your profile, but there are some applications which enable you to find out the profile visitor. How does this work?
They don't work. Such apps are rogue apps. You can confirm by seeing that the numbers, counts et al are the same for each person.
The whole idea is to get people to use it so that the app can steal personal data/use it for datamining or sell it off.
As Sathya says, these apps are fakes. Even apps that claim to make your visitors look like stalkers are fake. Never trust any app that claims to do this.
Most either fake the numbers, or use data collected from other people using the app (aka they ask your friends to join as well). Stalking apps just display the person's name - nothing clever.