First three problems solved
More effective algo for Problem 3
Cleanup