Let's say we have the following context free grammar:
$S \rightarrow a \\ S \rightarrow SS$
And we do the following two "derivations" for the same string:
aaa: $S \rightarrow SS \rightarrow SSS \rightarrow aaa$
aaa: $S \rightarrow SS \rightarrow SSS \rightarrow aSS \rightarrow aaS \rightarrow aaa$
The difference between the two derivation is that: in first derivation we just replaced multiple same variables at once, whilst in the second derivation we replaced multiple same variables one by one
Are these two different derivations? or just one derivation? Because their parse trees would look different. Which one should i stick to?