project 12 / knock lock: problem reading the input value of piezo

Man i was stuck on this for ages too, I just solved mine here is how: Red of the piezo to one leads of the resistor then to Analog 2. Black of the piezo to the other lead of the resistor and then to ground. On the arduino code, you have to to put:

analogRead(A2)

for some reason you have to put A2, idk why, and well at least it worked for me hope it helps