There are many ways to do this, but to clarify, are you trying to calculate the average between just two numbers (top and bottom numbers) or between a list of top numbers and bottom numbers?

What you plan to do with this calculated number? Do you need to store it or just display it on the fly? Are the numbers free-typed all the time or it will be get from some source in specific cases?