Simple reflection sensor

Hi there,
I have a mini project that if works well I will embbed it to bigger projects. I'm sure I'm not the first one to think about it but it is still cool.
Connecting a photodiode between 5V and Analog pin 0. I want to first see the changes in voltage through the serial monitor, and then I will say to the softwere:
When analog is bla bla turn buzzer pin HIGH. That way when I light a flashlight on the photodiode things change.

Can you help me with the softwere? I'm more a hardwere dude..

Sorry about spelling, my native langugue is not English.

Have a look at the AnalogInOutSerial example sketch.