On Sunday, April 12, 2020 at 5:43:42 AM UTC-4, jacobnavia wrote:
> Le 12/04/2020 à 11:21, Juha Nieminen a écrit :
> > Barry Schwarz <
schw...@delq.com> wrote:
> >> On Sun, 12 Apr 2020 10:15:11 +0200, jacobnavia
> >> <
ja...@jacob.remcomp.fr> wrote:
> >>
> >>> How do you replace an element at, say, position 4?
> >>
> >> Does
> >> vec[4] = value;
> >> not do what you want?
> >
> > More like vec[3] = value;
> >
> > (Although, admittedly, "position 4" is ambiguous, as it
> > could mean either one.)
> >
>
> OK, I suppose that any destructors for the old element are called of course.
operator. If a class type T were involved, then other possibilities come