#include <stdio.h>
#define sqr(x) (x*x)
int main()
{
int x=2;
printf("value of x=%d",sqr(x+1));
}
What is the value of x?
Answer Posted / jugal
Sorry guys,
my bad,
i thought it was
#define sqr(x) ((x)*(x))
the output wud be 5
but still the value of will be 2 only
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Differentiate between calloc and malloc.
How can you be sure that a program follows the ANSI C standard?
What are loops c?
In a switch statement, what will happen if a break statement is omitted?
What is the difference between union and anonymous union?
Which driver is a pure java driver
Write the control statements in C language
How can I find the modification date of a file?
What is double pointer in c?
In this problem you are to write a program that will cut some number of prime numbers from the list of prime numbers between 1 and N.Your program will read in a number N; determine the list of prime numbers between 1 and N; and print the C*2 prime numbers from the center of the list if there are an even number of prime numbers or (C*2)-1 prime numbers from the center of the list if there are an odd number of prime numbers in the list.
Explain the difference between call by value and call by reference in c language?
How can I call system when parameters (filenames, etc.) Of the executed command arent known until run time?
Devise a program that inputs a 3 digit number n and finds out whether the number is prime or not. Find out its factors.
What is masking?
what does static variable mean?