Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^4: Finding longest palindrome from a string

by ccn (Vicar)
on Aug 14, 2004 at 09:40 UTC ( #382926=note: print w/ replies, xml ) Need Help??


in reply to Re^3: Finding longest palindrome from a string (optimizing Perl)
in thread Finding longest palindrome from a string

Your benchmarking is not fair. The place is hihgly dependend on input data. E.g. if you use only     'abcdedcbabcdefgfedcbabcdefghijklmnonmlkjihgfedcbabcdefghijklkjihgfedcbabcdefghijklmnoponmlkjihgfedcba' you get other results.

I can't imagine a fair benchmark because it must go through all possible permutations for short and very very long strings. Or it must use random input data and calculate the statistics.


Comment on Re^4: Finding longest palindrome from a string
Download Code
Re^5: Finding longest palindrome from a string
by Aristotle (Chancellor) on Aug 14, 2004 at 09:48 UTC

    Go ahead, the code is there. :-) I simply took cLive ;-)'s code as a starting point myself.

    Makeshifts last the longest.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://382926]
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: (11)
As of 2014-09-30 18:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (380 votes), past polls