List comprehensions: ord : ord « Buildin Function « Python






List comprehensions: ord

List comprehensions: ord

res = [ord(x) for x in 'spam']    # apply expr to seq
print res

           
       

Related examples in the same category

1.ord function demoord function demo