On 13 fév, 21:24, 8 Dihedral dihedral88...@googlemail.com wrote:
Rick Johnson於 2013年2月14日星期四UTC+8上午12時34分11秒寫道:
On Wednesday, February 13, 2013 1:10:14 AM UTC-6, jmfauth wrote:
d = {ord('a'): 'A', ord('b'): '2', ord('c'): 'C'}
'abcdefgabc'.translate(d)
'A2CdefgA2C'
On Wednesday, February 13, 2013 1:10:14 AM UTC-6, jmfauth wrote:
d = {ord('a'): 'A', ord('b'): '2', ord('c'): 'C'}
'abcdefgabc'.translate(d)
'A2CdefgA2C'
def jmTranslate(s, table):
... table = {ord(k):table[k] for k in table}
... return s.translate(table)
...
d = {'a':
On 13/02/2013 16:34, Rick Johnson wrote:
On Wednesday, February 13, 2013 1:10:14 AM UTC-6, jmfauth wrote:
d = {ord('a'): 'A', ord('b'): '2', ord('c'): 'C'}
'abcdefgabc'.translate(d)
'A2CdefgA2C'
def jmTranslate(s, table):
... table = {ord(k):table[k] for k in table}
... return
On Wed, 13 Feb 2013 16:55:36 +, Mark Lawrence wrote:
On 13/02/2013 16:34, Rick Johnson wrote:
On Wednesday, February 13, 2013 1:10:14 AM UTC-6, jmfauth wrote:
d = {ord('a'): 'A', ord('b'): '2', ord('c'): 'C'}
'abcdefgabc'.translate(d)
'A2CdefgA2C'
def jmTranslate(s, table):
...
Rick Johnson於 2013年2月14日星期四UTC+8上午12時34分11秒寫道:
On Wednesday, February 13, 2013 1:10:14 AM UTC-6, jmfauth wrote:
d = {ord('a'): 'A', ord('b'): '2', ord('c'): 'C'}
'abcdefgabc'.translate(d)
'A2CdefgA2C'
def jmTranslate(s, table):
... table = {ord(k):table[k]
On Sunday, February 10, 2013 4:36:53 AM UTC-6, Johannes Bauer wrote:
On 09.02.2013 12:04, Joshua Robinson wrote:
Hi *Monte-Pythons*,
x = this is a simple : text: that has colon
s = x.replace(string.punctuation, ); OR
s = x.replace(string.punctuation, );
print x # 'this
On Saturday, February 9, 2013 5:04:18 AM UTC-6, Joshua Robinson wrote:
Hi Monte-Pythons,
x = this is a simple : text: that has colon
s = x.replace(string.punctuation, ); OR
s = x.replace(string.punctuation, );
print x # 'this is a simple : text: that has colon'
# The colon is still
On Tuesday, February 12, 2013 10:44:09 PM UTC-6, Rick Johnson wrote:
REFERENCES:
[1]: Should string.replace handle list, tuple and dict
arguments in addition to strings?
On 13 fév, 06:26, Rick Johnson rantingrickjohn...@gmail.com wrote:
On Tuesday, February 12, 2013 10:44:09 PM UTC-6, Rick Johnson wrote:
REFERENCES:
[1]: Should
On 09.02.2013 12:04, Joshua Robinson wrote:
Hi *Monte-Pythons*,
x = this is a simple : text: that has colon
s = x.replace(string.punctuation, ); OR
s = x.replace(string.punctuation, );
print x # 'this is a simple : text: that has colon'
# The colon is still in the text
Is this a
Hi *Monte-Pythons*,
x = this is a simple : text: that has colon
s = x.replace(string.punctuation, ); OR
s = x.replace(string.punctuation, );
print x # 'this is a simple : text: that has colon'
# The colon is still in the text
Is this a bug or am I doing something wrong ?
Py.Version: 2.7
On Sat, Feb 9, 2013 at 10:04 PM, Joshua Robinson
shooki.robin...@gmail.com wrote:
Hi Monte-Pythons,
x = this is a simple : text: that has colon
s = x.replace(string.punctuation, ); OR
s = x.replace(string.punctuation, );
print x # 'this is a simple : text: that has colon'
# The colon is
12 matches
Mail list logo