Oh boy...
The "Miracle on the Han River" in South Korea and Japan's post-war economic boom are massive subjects that economic historians have spilled gallons of ink over.
For Korea, a few factors:
U.S. aid - the U.S. government helped provided substantial direct and indirect aid to South Korea. Keeping South Korea from collapsing politically and economically after the Korean War was a key Cold War policy objective for the U.S. and they invested accordingly. This could be helping the South Koreans set up F-5E fighter jet production lines - which helped South Korea build its aerospace industry. One the main reasons Park Chung Hee sent South Korean troops to Vietnam was to secure further U.S. military and development aid.
Migrant labor - South Korea exported large numbers of workers overseas. For exampleb South Koreans worked as miners and nurses in East Germany and construction workers in the Middle East. Remittances from these workers helped inject cash into South Korea's economy.
Park Chung Hee and the chaebol - he's South Korea's most important and most controversial president. He took power in a coup, violently cracked down on people, embezzled millions, rigged elections, and effectively ruled as a dictator. But he also foild the North Korean mini-invasion of the 1960s and stopped the North from destabilizing the South. He aggressively managed the South Korean economy. He'd literally call up favored business people and tell them to start new business ventures he thought were strategically important for South Korea. The governmen would throw some cash at the project to get things off the ground. Hyundai, for example, got its start as a construction company. Thanks to pressure from Park and his initial investments, it moved into ship building - it now has some of the biggest shipyards in the world. Virtually all of the big chaebol ("wealth clan") industrial conglomerates like Samsung, Lotte Group (LG), Hyundai, and Daewoo got their start during the Park era. They have incredibly diverse business portfolios. Samsung makes phones, appliances, cars, and ships. It also runs hotels, banks, and amusement parks. Lotte Group does everything from make dishwashers to run a Disneyland knockoff literally called "Lotte World." The fact the chaebol do so many things is partly due to Park's ecencouragement, support, and arm-twisting. Even today, the big businesses have very close ties to the government - periodically, politicians and chaebol members are getting snarled up in corruption scandals. Thr success of the chaebol in building up Korea's service sector and heavy industry is a huge part of the South Korean success story. Today Samsung alone accounts for nearly 20% of Korea's GDP.
Timing - South Korea was China before China was China. Think cheap labor and the ability to quickly build a ton of light industry - and a world market hungry for cheap goods in the 1960s and 1970s.