Re: Micro-PEP: str.translate(None) to mean identity translation
- From: "M.E.Farmer" <mefjr75@xxxxxxxxxxx>
- Date: 30 Apr 2005 10:12:27 -0700
After I re-read your post in daylight and read your followup the "Aha!"
hit me .I am a little slow at times. I have always just iterated thru
the badchars and replaced with "" . What you suggest would be very
nice indeed!
Thanks for the time and explanation, and you too Peter !
For what it is worth +1 ;)
On another note why is maketrans in the string module....
I was a bit lost finding it the first time should it be builtin?
transtable = "abcdefg".maketrans("qwertyu")
Probably missing something.
M.E.Farmer
.
- References:
- Micro-PEP: str.translate(None) to mean identity translation
- From: Bengt Richter
- Re: Micro-PEP: str.translate(None) to mean identity translation
- From: M.E.Farmer
- Re: Micro-PEP: str.translate(None) to mean identity translation
- From: Bengt Richter
- Micro-PEP: str.translate(None) to mean identity translation
- Prev by Date: lists in cx_Oracle
- Next by Date: Directory in Windows
- Previous by thread: Re: Micro-PEP: str.translate(None) to mean identity translation
- Next by thread: Re: Micro-PEP: str.translate(None) to mean identity translation
- Index(es):
Relevant Pages
|