The Great Wall of China was constructed by the Qin Dynasty. Its purpose was to keep barbarians like the Mongols away from the more populated Han China.
It didn't really work though because barbarians, again, the Mongols, went around it.
It is now just used as a massive tourist attraction bringing in almost 10 million tourists a year. Basically its just a big source of revenue now.
Explanation:
2,300 years ago the first sections of the Great Wall were built to keep outsiders out, but ironically it is now rebuilt to draw tourists in. Over the centuries, the Great Wall has been built and rebuilt for three main purposes: as kingdom border defenses, to defend China's northern border, and for tourism.