added function for reading answer