Czar
01/18/2018, 11:33 AMit.iDestGroup = 15 is an assignment and as such does not return anything, therefore: Unit and as a result you get a List<Unit>. Mapping operation creates new list with values from the receiver transformed according to the map closure.
apply returns the receiver, so you get a new list containing transformed values of the receiver list. @petersommerhoff is right, you probably do not want a new list here.