Fixed running of examples in batch for python2 and python3

These changes were made while testing stability of pytables-3.1.1-r1 package on x86 system on Gentoo/Linux. 

Examples that are commented-out in `examples/check_examples.sh` don't run successfully either with Python3 or with Python2. All examples that aren't commented-out run successfully with Python2 and Python3.

Please check "TO DEBUG" section at the end of `examples/check_examples.sh` script for the list of "broken" example scripts.