# How to add Two Number without using Operator in C?

You may have read my previous article where I have mentioned C is one of the simplest programming languages. It’s for beginners. If you want to be the master of C you have to explore and try new things. Or you should keep exploring for doing the same things in many ways.

In this code, I will share how you can add two number without using the operator in C.

### How to add Two Number without using Operator in C?

This is one of the tricky questions asked in many of the placement interviews.

#### Solution 1: Using printf() Function

If you find the difficulty in writing this code, here is a hint for you.

Hint: You can do this by using `printf()` function which returns the number of characters written to the output console.

Minimize the browser and try this program by user self first.

```#include<stdio.h>
{
printf(“%d”,printf(“%*c%*c”,m,’ ‘,n,’ ‘));
}
void main()
{
}```

Note: This program also prints the white spaces on the output console. You can ignore as it is not visible.

#### Solution 2: Using math.h library

This solution is provided by Fulvio Baccaglini.

You can use `math.h` library. Here is an idea, based on math.h atan2 performing a division, and some auxiliary transformations, to turn the division into multiplication, and then multiplication into addition.

Note: This solution is not purely without operates as we are using exp, pow…  operators. We can only say, this solution is without addition operators.

```#include<stdio.h>
#include<math.h>

{
int nSum;
nSum = log (tan (atan2 (exp (m), pow (exp (n), floor (log (0.5))))));
printf("%d", nSum);
}

void main()
{