Arduino Code for Force Resistor Rhythm Sensing? Please Reply

So, I have a circuit and sketch for moving a servo to 33° if you press on a force-sensitive resistor(pin A0) and gradually press harder over 1.65 seconds. After that it will check how much light there is from a light dependent resistor(pin A1) and do nothing while the light is over a certain threshold. If the light goes below that threshold, it moves the servo to 130°. I would like to make it where it would work like this except I would instead tap a certain rhythm on the force resistor, at any speed. What modifications to the code would let it do this? Here’s part of my code below:

val = analogRead(fr); //sample 1 of the force resistor
delay(200);
val1 = analogRead(fr); //sample 2
delay(200);
val2 = analogRead(fr); //sample 3
delay(200);
val3 = analogRead(fr); //sample 4
delay(200);
val4 = analogRead(fr); //sample 5
delay(200);
val5 = analogRead(fr); //sample 6
delay(200);
val6 = analogRead(fr); //sample 7
delay(200);
val7 = analogRead(fr); //sample 8
delay(200);
val8 = analogRead(fr); //sample 9
delay(200);
val9 = analogRead(fr);  //sample 10
delay(200);
val10 = analogRead(fr); //sample 11
delay(200);
val11 = analogRead(fr); //sample 12
delay(200);
if (val < val1 && val1 < val2 && val2 < val3 && val3 < val4 && val4 < val5 && val5 < val6 && val6 < val7 && val7 < val8 && val8 < val9 && val9 < val10 && val10 < val11) { //if each sample is less than the next
myservo.write(33); //move the servo to 33°
ldrval = analogRead(ldr); //get a value from the light dependent resistor
   while (ldrval > 19) { //while the light is above a threshold
    delay(2500); //delay //do nothing for 2.5 seconds
    ldrval = analogRead(ldr); //check the light again
   }
myservo.write(130); //move the servo back to 130°
delay(200);
}

Thanks,
Greg