Added types subchapter
doctest fixes