How is the state of a GPIO pin detected?

Massimo Banzi, in his TED Talk on Arduino, thanked the Arduino community for being the best in the world. He was right. It is a privilege to have access to such knowledgeable people who are more than happy to share their expertise.

Thanks, guys!