A little bit of fixing of the code and printouts