Progress on Types.... Cleaned up code