added tostring function for books