stripping parts of elements in a list

CSUIDL PROGRAMMEr syedamjad_a at yahoo.com
Sat Oct 28 14:00:34 EDT 2006


folks,
I am  new to python.

I have a list made of elements

['amjad\n', 'kiki\n', 'jijiji\n']
I am trying to  get rid of '\n' after each name.
 to get list as
['amjad','kiki','jijiji']

But list does not have a strip function as string does have.

is there any solutions

Is there a way this can be done??




More information about the Python-list mailing list