changed SortedPartsChain : added getFromLast, getFromFirst
changed TestSortedPartsChain : test for getFromLast, getFromFirst