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:
http://www.opengl.org/discussion_boards/ubb/Forum2/HTML/003547.html http://www.opengl.org/discussion_boards/ubb/Forum2/HTML/000974.html http://www.opengl.org/discussion_boards/ubb/Forum2/HTML/000131.html

mmmmm search engines

Thanks. Exactly what i was looking for.