frames per second counter?

I would like to add a fps display to my openGL program. How can i find out the current fps being rendered?

Clicking on Search, and punching in “frames per second”, I came up with the following:

mmmmm search engines

Thanks. Exactly what i was looking for.