updating Group
revamped storeElementsByOrder in Group.java