Over the period from the mid-11th century to the mid-14th century, Scotland changed its method of appointing its High Kings from the rules of tanistry (election from a shortlist of people of royal blood) to the rules of primogeniture (automatic inheritance of the title by the eldest direct heir). It was a gradual change which (arguably) started when the sons of Malcolm Canmore by his second marriage (to Margaret Atheling, whose influence on the country was profound in the way that she brought new cultural influences into the country) took their turn in being King. It was (arguably) completed following the untimely death of Margaret, the Maid of Norway, after whom there was no clear successor. Edward I of England was called in to adjudicate on who her successor should be. There is no need to report here on the way that he exploited his position to his advantage but the experience of that exploitation completed the lesson that (in Medieval times at least) it was better to have a clear succession even if that meant a weak sovereign rather than having disputes each time a reign ended.