improve efficiency

print out process
reduce search length