How to Calculate value of a global declaration equation

Viewed 8

I calculate the value of equation is 4 and the program give the same result but when I calculate the value of x*x is 16 this time the program give the result 23. I can not understand how to possible ?

#include<bits/stdc++.h>
#define x 9+2/4*3-2*4+(5-4)*3
using namespace std;
int main()
{

    int i=x;
    int j=x*x;

    printf("%d , %d \n",i,j);



}


   
0 Answers
Related