i know what attack and other stats are for but speed so what if the Pokemon's speed? theres no moves that need speed to defend or attack can someone tell me what is the use of speed
Speed is what governs who attacks first. Higher speed means you'll attack first
Some moves like Electro ball do damage based on speed. Electro Ball will deal damage if the user is faster, Gyro ball will deal more damage if the user is slower.
In Gen 1, It also governed a Pokemons critical hit rate. Being fast would mean you were more likely to land a critical hit. This was changed for obvious reasons.
Having higher Speed means you will attack first in most cases. So if both Pokemon's HP is low, you will probably KO your opponent before they get a chance to hit you.
There are a few moves such as Electro Ball that inflict greater damage if you are much faster than your opponent. And moves like Payback where if you are slower and so go second in the turn, the power doubles.