In transposition of the great arteries, the normal position of the arteries is reversed. The aorta comes out of the right ventricle (instead of the left), and the pulmonary artery comes out of the left ventricle.
This means that the right ventricle pumps blood to the body and the left ventricle pumps blood to the lungs. The problem with this is that oxygen-rich blood returns to the lungs while oxygen-poor blood gets carried to the rest of the body.
The only way for oxygen-rich blood to reach the body is through another defect that connects the two routes. An atrial septal defect allows the exchange of blood between the two atria, a ventricular septal defect allows the exchange of blood between the two ventricles, and a patent ductus arteriosus connects the pulmonary artery and the aorta.