Re:What I learned from my first C coding challenge
by csense on Wednesday September 05, 2012 @10:17PM
(#4482544)
It also depends on the assumptions we make about the problem.
- Do we have to validate the URL strings in any way?
- What do we need to do with duplicate names?
- Are cases with small parameter names and/or small numbers of parameters common?
- How common are parameters with lengthy common prefixes?
- Is there a bound on the length of the longest common prefix of two different parameter names?
Tuning or special-casing with common cases in mind can often produce big wins.
- Average number of parameters
- The % that are already sorted
- The % that don't have keys that start with same letter