One thing I "learned" when interviewing new grads was that all numbers are ints and all data structures are lists. :-)
Any question that required a set, a map, or a floating point number would quickly weed out about 90% of candidates. On Mon, Sep 23, 2024 at 11:08 AM Martin Desruisseaux <[email protected]> wrote: > > Le 2024-09-23 à 12 h 53, Gary Gregory a écrit : > > > > Speaking of collections... In some code bases I review (not here) a > > List is often used when a Set would semantically correct. Is there an > > opportunity in m3 or m4 for such a change? > > > Yes, I also though about that. Especially since I have seen code like > that in the Maven code base: > > if (!list.contains(stuff)) { > list.add(stuff); > } > > When above code is called in a loop, for a list large enough, it can > contribute to slow down Maven. However since it may breaks API, I though > to keep that for another round. > > Martin > -- Elliotte Rusty Harold [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
