Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > comparison puzzle? bug?

Reply
Thread Tools

comparison puzzle? bug?

 
 
Charles Hixson
Guest
Posts: n/a
 
      03-23-2005
I hesitate to call this a bug, as at my level of expertise that seems
.... unlikely. But I can't think of any other explanation:

This is an extract from some longer code:
print "item = ", item
print "item[0] < lvl = %d < %d = " %(item[0], lvl), bool(item[0] < lvl)
print "item[0] == lvl = %d == %d = " %(item[0], lvl), bool(item[0]
== lvl)
print "item[0] > lvl = %d > %d = " %(item[0], lvl), bool(item[0] ==
lvl)
yields:
item = [1, 'A', '/home/.../data/n1a.gif', <Surface(102x78x32 SW)>]
tem[0] < lvl = 1 < 0 = False
item[0] == lvl = 1 == 0 = False
item[0] > lvl = 1 > 0 = False

I abbreviated that file path. Any ideas what's going on?
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Comparison of 2 files and generating the output based on comparison Deepu Perl Misc 1 02-07-2011 03:09 PM
Price Comparison Service. Best Deal. Special Coupon atBest-Price-Comparison.com rapee Digital Photography 0 03-14-2008 06:46 AM
Desktop Graphics Card Comparison Guide Rev. 9.2 Posted! Silverstrand Front Page News 0 08-22-2005 04:08 PM
Good comparison of IE to FireFox security record Tom Betz Firefox 0 05-13-2005 04:54 PM
.Net Comparison LV ASP .Net 4 08-31-2003 09:15 PM



Advertisments