I do not understand how this flatten with extend and append works for ...

I do not understand how this flatten with extend and append works for ...

More to explore

Based on this image's title: “I do not understand how this flatten with extend and append works for ...