Sonar sensor to arduino to servo

but it does not stores the data from the sensor.

See my last comment.

Stop calling me "sir".