Added complete exhaustive search