Update main.py

revised code significantly to make it less messed up... :)