Cleaned up code
Compiled Min