Trending This Week:

test

Post Top Ad

Your Ad Spot

Monday, June 20, 2022

C++ Program to print sum of two numbers without using "+" operator.

      





C++ Program to print sum of two numbers without using "+" operator.


#include <iostream>
using namespace std;
int main ()
{
    int a,b,c;
    cout<<"Enter Value For A: ";
    cin>>a;
    cout<<endl<<"Enter Value For B: ";
    cin>>b;
    c=a-(-b);
    cout<<endl<<"Ans is : "<<c;

    return 0;
}

Output :






Hash Tags:

#CPP #Calculation #SumOfTwoNumbers #Plus #Programming #coding #Addition #Code #SourceCode #java #CLanguage #Python #Logical #Maths




No comments:

Post a Comment

Post Top Ad

Your Ad Spot