the West, the term mandarin is associated with the concept of the scholar-official who immersed himself in poetry, literature, and Confucian learning in addition to performing civil service duties. In modern English, mandarin is also used to refer to any (though usually a senior) civil servant, often in a satirical context, particularly in the United Kingdom and Commonwealth countries. The speech standard of the Ming and Qing empires was called "Mandarin language" by European missionaries, translating the Chinese name Guanhua ("the language of the officials") for this speech standard, which was current already in the Ming dynasty. The term "Mandarin" is also used to refer to modern Standard Chinese, which evolved out of the earlier standard, and to the broader group of Mandarin dialects spoken across northern and southwestern China. History In China, from 605 to 1905, mandarins were selected by merit through the extremely rigorous imperial examination. China has had civil servants since at least the Zhou dynasty. However, most high ranking positions were filled by relatives of the sovereign and the nobility. It was not until the Tang dynasty when imperial examination replaced the nine-rank system and the final form of the mandarin was completed. Mandarins were the founders and core of the Chinese gentry. A governmental office (for example, a central government department or a provincial civil governorate) headed by a mandarin is called a yamen. The mandarins were replaced with a modern civil service after the fall of the Qing dynasty. During the Qing dynasty, the governor of a Chinese province was signified by wearing a mandarin hat-pin made of ruby. The lower ranks of mandarins were signified by hat-pins made of coral, sapphire, lapis lazuli, white jade, gold, and silver. After becoming free of Chinese rule and setting up its own independent monarchy, Vietnam emulated the Chinese system of mandarins in its civil service. The last mandarins in history were in service of the State of Vietnam (1949–1955). The Confucian examination system in Vietnam was established in 1075 under the Lý dynasty Emperor Lý Nhân Tông and lasted until the Nguyễn dynasty Emperor Khải Định (1919). Elephants were used to guard the examination halls until 1843 when the emperor said it was no longer necessary. Korea adopted the civil services examinations called Gwageo under the Goryeo and Joseon dynasties. Based on the civil service examinations of imperial China, the gwageo first arose in Unified Silla,