I gave birth to chicks with less than 20 lines of code.

7 min readJul 14, 2021

One day, not so long time ago, I decided to try myself at maternity. Or paternity. I tried parenting !

I’ll explain you how to give birth to chicks with just some lines of code.

I live in a farm and in a farm we have animals: cats, bees, cows and hens. Hens are great! Firstly because chickens are closer to dinosaurs than alligators which is cool and secondly because they are easy to breed! They eat almost everything! They don’t require a lot of attention, they live outside and each of my hens produces one egg each 16 hours of sunlight. Which makes approximately 300 eggs per hen and per year 🥚

We recently bought a rooster (chicken dad). Now our eggs are not just emtpy egg cells but they can be hatched to produce chicks ! Once in a while a hen will start to hatch eggs. While doing it the hen will almost stop eating stop producing other eggs. Most of the time and for no obvious reasons it’s not very successful.. So, I decided to help them. But first we have to understand what does a chicken egg need?

What is an egg ?

An egg is composed of an eggshell, a yolk (yellow) an albumen (white part) and the most important the embryo. The chick will grow inside eating the yolk. Once the chick is big enough it will break break its shell with its beak.

What does a chicken egg need?

Unlike mammals, for birds (and reptiles) gestation occurs outside the mother. The egg contain everything the embryo need and the mother (hen) will provide the following :

  • 21 days of incubation (19 to 23 days)
  • A temperature of around 37.5 °C
  • Day 1 to 19 — 40% of humidity
  • Day 19 to hatching — 65% of humidity
  • Eggs need to be turned minimum once a day from day 2 to day 19.

Easy no ? How can I imitate…


Data Science - Biology 🇫🇷🇺🇦