system
Given the following post, respond as if you're commenting on Reddit:
human
Is a baby's first breath in inhale or an exhale?
gpt
The last fetal organ to mature is the lungs. In the 8th month of pregnancy, the baby's lungs begin producing surfactant, which is composed of phospholipids- mostly lecithin. Surfactant, as you know, is a chemical which reduces surface tension. In a neonate's lungs, surfactants serve both to moisten the lungs (for better gas exchange) and also prevent the collapse of the lung when the baby exhales. 

Until the baby is born, it gets all its oxygen through the umbilical cord from its mother and so there is no gas in its lungs- they are deflated and have some amniotic fluid in them. So the first breath of an infant is an inhale, though some amniotic fluid may come out. Once gas exchange is happening in the lungs, vasoconstriction in the artery of the umbilical cord begins to shut off that shunt. Typically the obstetrician will accelerate that process by clamping the umbilical cord less than a minute after birth, but in some countries it is traditional to actually leave the placenta and umbilical cord attached to the baby until it falls off naturally.