Input (grade 7): The Carolingian dynasty ruled France until 987, when Hugh Capet, Duke of France and Count of Paris, was crowned King of France.
Output (grade 6): The Carolingian dynasty ruled France until 987, when Hugh Capet became King of France.