if arteries carry o2 and veins co2, then don't the gases get mixed when capilaries become veins??
No,
Capillary network is a web-like network of capillaries, embedded in tissue, connecting arteries and veins which run parallel throughout the body.
Capillaries are tiny blood vessels, of approximately 5-20 micro-metres. Network of capillaries are supplied with blood by arterioles and drained by venules. Capillary walls are only one cell thick which permits exchanges of material between the contents of the capillary and the surrounding tissue.
The blood enters the capillary from artery and there will be high blood pressure in the capillary vessel and that fluid moves from the vessel to the body tissue. At the middle the blood pressure in the vessel equals the osmotic pressure and the fluid passes equally between the capillary vessel and the body tissue.