One Reply to “Program to find the biggest among three numbers using pointer”

  1. using namespace std;

    void greatest(int *a,int *b,int *c)
    {
    if(*a>*b && *a > *c)
    {
    cout<<*a<<" is greater"< *a && *b > *c)
    {
    cout<<*b<<" is greater"<<endl;
    }else{
    cout<<*c<<" is greater"<<endl;
    }
    }
    int main()
    {
    int a =2;
    int b = 3;
    int c = 10;

    greatest(&a,&b,&c);

    return 0;
    }

Leave a Reply

Your email address will not be published. Required fields are marked *