Servo problems

I recently bought 4 Goteck micro metal gear servos with the intention of using them to move some joints in my 3d printed robot. I decided to test them onviously and ran some simple code on my Arduino (basicly cantering the servo, moving it to the left and then right). I had run this code before with some other servos which worked fine but these ones seemed to act weirdly. Instead of jumping straight to the right position they flapped around a bit before stopping at the right place. Sometimes they would “flap” over the right spot up to 4 times before coming to a stop and sometimes worked properly. These servos are advertised as “perfect for model aeroplanes and helicopters” but I think if I was to use them the model would be unflyable.

Is it something to do with the PWM of my Arduino UNO or am I using the servos wrong and is there a way to fix it?

The code I am using is:
#include <Servo.h>
Servo servo1;
void setup()
{
servo1.attach(9);
}
void loop()
{
int position;

servo1.write(90);
delay(2000);
servo1.write(180);
delay(1000);
servo1.write(0);
for(position = 0; position < 180; position += 2)
{
servo1.write(position);
delay(20);
}
}

Thanks for the help

It sounds like their dead

It sounds like their dead band is too small for the inertia of whatever they are moving. Have you tried to move them slower, for instance with the Sweep example from the Arduino library? Also, are you sure you are powering them with the right voltage and not higher?

Thanks a lot
Like I said above ^^ I got them working. Thanks for your help