changed normal algorithm
changed search in element list to list search (speedup)