The book is written in an exploratory style: try something and then understand how it works. It will guide you …