Create memory.py

This was my solution to "Memory"