changed print statements to Python2 and Python3 compatible ones