no copy array needed anymore and array accesses divided in 2
However, as a result there are also possible subsolutions found and
removing duplicates had to be enhanced.
result: same functionality as before but even slower on big problems