[Tutor] comparing strings

bob gailer bgailer at gmail.com
Fri Feb 25 09:59:54 CET 2011


On 2/25/2011 3:23 AM, Corey Richardson wrote:
> On 02/25/2011 02:53 AM, Edward Martinez wrote:
>>       Thanks for the reply. i now understand that python uses either
>> ASCll or Unicode to compare and to do other things

When comparing string (not unicode) Python uses the underlying hardware 
character representation. This is not always ASCII. On IBM Mainframes it 
is EBCDIC. The ord values are different, and the order is different.

See http://www.dynamoo.com/technical/ascii-ebcdic.htm


-- 
Bob Gailer
919-636-4239
Chapel Hill NC



More information about the Tutor mailing list