In ancient China, Go was often seen as the refined pastime of the scholars, while xiangqi was the game of the masses. According to Japanese historian Miyoshi, Go flourished in China from about A.D. 200 to 600, when the interest in art and literature was at a high point. Go was one of the four cultivated arts of the Chinese scholar gentleman, along with calligraphy, painting and playing the musical instrument guqin, and examinations of skill in those arts was used to qualify candidates for service in the bureaucracy. First founded books devoted to the game were written during the Tang dynasty and the Sung dynasty.