Greatly improved speed and lines of code.