finish collection contains array and dictionary and add control-flow