Improved-complexity maximal clique implementation passing test cases