Added stdlib.h to use exit function