Dynamic FPS

I don’t quite grasp the idea of dynamic FPS. I want to see the FPS depending on how many objects I got on the screen and so forth.

I’d like to try to get these work, so basically what is the general idea?

Should I set the FPS so way too high and then count how many times the screen was painted? Something doesn’t sound right.

Is there any way to set the game to draw as many times as possible within the interwal and then count how many actually did happen?