I doubt the question will be retained, still (it is an application of Weighted Mean):
$$((p*q) + (s*t) / (q+t))$$
Where,
p - Price of item 1
q - Qty of item 1
s - Price of item 2
t - Qty of item 2
So,
$$((100*100)+(125*100))/(100+100)) = 125$$
The solution to the second part of the question is left as an exercise to the reader. ;)