Files
Pyarmor-Static-Unpack-1shot/tests/tokenized/iter_unpack.txt

9 lines
180 B
Plaintext
Raw Normal View History

def map_with_index ( func , lst ) : <EOL>
<INDENT>
res = [ ] <EOL>
for i , x in enumerate ( lst ) : <EOL>
<INDENT>
res . append ( func ( i , x ) ) <EOL>
<OUTDENT>
return res <EOL>