How To Check Output In Python