Source Code
#include<iostream> #include<conio.h> using namespace std; int main() { //to clear the screen float a,b,c,sum,av; cout<<"Enter three numbers:"; cin>>a>>b>>c; sum=a+b+c; av=sum/3; cout<<"\nSUM="<<sum; cout<<"\nAverage="<<av; getch(); //to stop the screen }
Output
0 comments:
Post a Comment