as everybody else has said - Magnesium, Potassium, Sodium.....in no particular order, all linked somehow, lack of any/all of them can cause cramps.
Although I quite like bree's response, your leg COULD be falling off you know, WAY more interesting than boring old mineral deficiencies *yawn*...