How to add two numbers without using arithmetic operators?

Answer Posted / ramanareddy

#include<stdio.h>
#include<conio.h>
void main()
{
int a,b,c;
clrscr();
printf("enter the two numbers");
scanf("%d %d",%a,&b);
c=(-(-a-b));
printf("sum is = %d",c");
getch();
}

Is This Answer Correct ?    0 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Hai,I have done with my bachelor of commerce and planing to ms,please suggest me how to convince vo for shifting from commerce to computers. Visa on 8 DEC 2014  Npu university

1842


How can you restore a redirected standard stream?

832


what is the syallabus of computer science students in group- 1?

2104


What is the purpose of macro in C language?

890


What is the difference between fread and fwrite function?

881


What is indirection in c?

843


Is it better to bitshift a value than to multiply by 2?

894


What is difference between structure and union with example?

854


What are the preprocessor categories?

862


Define the scope of static variables.

865


a single linked list consists of nodes a to z .print the nodes in reverse order from z to a using recursion

2587


What is a substring in c?

828


write a program to convert a expression in polish notation(postfix) to inline(normal) something like make 723+* (2+3) x 7 (not sure) just check out its mainly printing expression in postfix form to infix.

2570


write a c program in such a way that if we enter the today date the output should be next day's date.

1945


What is the value of c?

818