If they are instances of the same object, give them a instance Boolean 'Picked'.
If they are different objects, add them all to a family, and assign the Boolean 'Picked' to the family.
Some condition that captures when this can happen. <-- no idea, you did not explain this part.
________Set 'Picked' to false <-- set them all to the starting point
___For each dictionary key
___Pick object with UID = int(Dictionary.CurrentKey) (or CurrentValue, depends on how you filled it)
________Set 'Picked' to TRUE for the picked object
___Is boolean instance variable set (for object) < picks those we marked in previous loop
___Pick highest/lowest (instance var for object)
________At this point the object is picked and you can trow actions at it