What is the advantage of using #define to declare a constant?


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More C Interview Questions

Write a C++ program without using any loop (if, for, while etc) to print numbers from 1 to 100 and 100 to 1;

18 Answers   Accenture, Cisco, Egentec, HCL, Ideaz, Infosys, M-Systems, MYR, TCS,


int a[3][5]={ {1,2,3,4,5],{2,3,4,5,6},{10,11,12,13,14}}; int *p=&a; printf(ā€œ%dā€,*(*(x+1)+3));

2 Answers   Wipro,


What do you mean by dynamic memory allocation in c? What functions are used?

0 Answers  


write the output of following code .. main() { static int a[]={10,20,30,40,50}; int *ptr=a; static int arr[2][2]={1,2,3,4}; char str[]="ABCD * 4#"; char *s=str+2; int i,j; for(i=0;i<5,i++) printf("%d",*ptr++); for(i=0;i<2;i++) for(j=0;j<2;j++) printf("%d\n",*(*(n+i)+j)); printf("%c\n%c\n%c\n",*(str+2),*s++,*--s); }

1 Answers  


The number of bytes of storage occupied by short, int and long are a) 2, 2 and 4 b) 2, 4 and 4 c) 4, 4 and 4 d) none

0 Answers  






Program to find the absolute value of given integer using Conditional Operators

6 Answers   N Tech,


Explain what are the standard predefined macros?

0 Answers  


6. Which of the Following is not defined in string.h? A)strspn() B)strerror() C)memchr() D)strod()

2 Answers   Accenture,


Write a program that takes a 3 digit number n and finds out whether the number 2^n + 1 is prime, or if it is not prime find out its factors

3 Answers  


Write a programme to find even numbers without using any conditional statement?

3 Answers   ADD Software, Infosys,


difference between Low, Middle, High Level languages in c ?

0 Answers   Bosch, Infosys,


what is stack , heap ,code segment,and data segment

0 Answers  


Categories