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
<martin.desruisse...@geomatys.com> 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
elh...@ibiblio.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org
For additional commands, e-mail: dev-h...@maven.apache.org

Reply via email to