Online Computer Courses Classes and Training Program

Find average on c++

#include<iostream>
using namespace std;
main()
{
    int n1,n2,n3,n4,n5,average;
    cout<<" Enter five number:-";
    cin>>n1>>n2>>n3>>n4>>n5;
    average=(n1+n2+n3+n4+n5)/5;
    cout<<" Average of five number is:-"<<average;
    return 0;
}

Post a Comment

0 Comments