python script from books