How did Qin Shihuang resist the invasion of Xiongnu?

Xiongnu is an ancient nation in northern China. During the Warring States period, it was in the early stage of slavery. Xiongnu slave owners and nobles often led troops to plunder in the south. Therefore, Qin, Zhao and Yan Dou built the Great Wall in the north to defend themselves. 2 15 years ago, Qin Shihuang sent Meng Tian with 300,000 troops to chase the Xiongnu in the north and recover the area south of Hetao. In the second year, Meng Tian crossed the river again, captured Yinshan Mountain, and set up 44 counties there. In order to prevent the Huns from going south again, Qin Shihuang ordered the Yanzhao and Qin Changcheng to be integrated, starting from Lintao in the west, ending in Liaodong in the east, with a total length of more than 5,000 kilometers, which was called the Great Wall of Wan Li in history, thus alleviating the serious threat of the Northern Qin Dynasty and ensuring the economic and cultural development of this area.