Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re^2: Comparison by position and value

by BrowserUk (Pope)
on Jan 03, 2005 at 18:59 UTC ( #419104=note: print w/replies, xml ) Need Help??


in reply to Re: Comparison by position and value
in thread Comparison by position and value

Your code appears to fail on '__8_3__19' and '84____7__', passing this as compatible when it should not be as the digit 8 appears in both strings in different positions.

It could be that in moving your function into my test script, I have broken it, but as your post doesn't contain a stand-alone testcase that I can run, I cannot verify this conjecture.


Examine what is said, not who speaks.
Silence betokens consent.
Love the truth but pardon error.

Replies are listed 'Best First'.
Re^3: Comparison by position and value
by Aristotle (Chancellor) on Jan 03, 2005 at 20:40 UTC

    Are you sure it's my posted code? I just dropped your example into my test suite as an incompatible case and it passes.

    Makeshifts last the longest.

      You're right, I screwed up. Sorry for the false call.


      Examine what is said, not who speaks.
      Silence betokens consent.
      Love the truth but pardon error.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://419104]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2020-05-31 04:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (173 votes). Check out past polls.

    Notices?