Create P38.py: Fast, but code can use some refactoring