Legalism thought the idea that humans were naturally bad and greedy. Therefore they needed a strong, controlling government to govern them. This was largely seen during the Qin dynasty in China under Qin Shi Huangdi. Confucianism on the other hand stressed merit within government as well as the five relationships. Government should be grounded in education and should act in the interest of the people. The five relationships helped to establish social harmony. It was the basis of civil service exams people entering government positions had to take. Was very common in many parts of Chinese history, but especially the Han dynasty.