brute force, large test cases failed
linear time complexity, large cases passed