Ok...now i get you. I perhapds did mis-understand you initially. So what you'll have to do (this isn't the entire answer, but it's a start):
#include <iostream.h>
//other headers
using namespace std;
main()
{
int num; //user input
int a,b; //used for integer division and modulus operations
cout <<"Enter a two digit number." <<endl;
cin >> num;
#= #/10; //do calculation
# = #%10;//do calculation
cout<<#<<#<<endl;
double average = (# + # )/2;
cout<<average<<endl;
enough spoon feeding, you can figure out how to do the rest...or fill in the blanks, show us what you've come up with!