#include <conio.h>
#include <iostream.h>
main () {
float r,g,n;
cout<<"enter r value : "; cin>>r;
cout<<"enter g value : "; cin>>g;

//n = r<g ? g-r : r-g;
n=(r+g)*0.5;
cout<<"value : "<<n;
getch(); 
return 0;
}