TP3 - Finished Brute Force Algorithm