added basics for quick sorting instance contents
did a merge