Weighted average for HP 15c
A short one:
This is intended to have an average of X weighted by y. For example: you enter 100 tons (ENTER), 2000 €/T (SUM), 200 T (ENTER, 2250 €/ton (SUM), ..., then you want to know the average price of the entered quantities.
The short program:
LBL 0 (so that it is on top of the average key)
RCL 7
RCL / 5
RTN
Short, isn't it? RCL 5 gives as well the total tons in this case