Hi everyone,
I'm new to python and I'm trying to reduce code length. Is there an efficient way to rewrite this simple code?
Thanks for the help!
Xav
I'm new to python and I'm trying to reduce code length. Is there an efficient way to rewrite this simple code?
Thanks for the help!
Xav
def config_WOpick(lst): for k in lst: position=0 if k.startswith('M1CW') or k.startswith('1CW') or k.startswith('CW'): for j in k: position+=1 if j=='W': print(k[position:])#insert the renaming action here later on