[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: [QUIZ] IP to Country (#139

steve d

9/17/2007 10:36:00 PM

> I changed to while low < high, and also the walking backwards failed> when reading the first line (btw, Steve, won't your solution also fail> for that case?).Yea it seems that mine will loop forever if you give an invalid ip address that evalutes to less than 0. Changing to 'low < high' seems to fix that. Also it incorrectly reports nil instead of no country on 0.0.0.0. This is all running on the stock csv file (with comments), haven't tried it at all on a modified file.- steve