--ini-enunciat >>> import valors >>> it1 = iter([2, 3, 3, 4, 6, 11, 9, 6]) >>> it2 = valors.transforma_seq(it1, 3) >>> next(it2) 2 >>> next(it2) 3 >>> next(it2) 4 >>> for v in it2: ... print(v, end=";") 6;8.5;11;9;6; >>> it2 = valors.transforma_seq(iter([1, 2, 2, 2, 5, 6, 9, 2, 2, 10]), 2) >>> for v in it2: ... print(v, end=";") 1;2;3.5;5;6;7.5;9;5.5;2;6.0;10; --fi-enunciat