what is diference between return 0 and return NULL??
Answers were Sorted based on User's Feedback
Answer / sourabh
return 0 means the function returns the particular value 0
returnn null means the function does not return any value'
Is This Answer Correct ? | 5 Yes | 1 No |
Answer / dips
return 0 is indicatiion of successsfull completetion of
programme generally we write return 0 for that purpose
return null its returnig nothing in some condition we may
dont require to return any value
Is This Answer Correct ? | 3 Yes | 2 No |
Answer / bajishareef
o is the value oriented decimal constant which is of integer type.
Where as NULL is the address oriented empty value.
Both are not equal
Is This Answer Correct ? | 1 Yes | 2 No |
main() { int x=5,y=10,z=0; x=x++ + y++; y=y++ + ++x; z=x++ + ++y; printf("%d%d%d\n",x,y,z); }
Can a variable be both const and volatile?
triangle number finding program...
What is difference between structure and union in c programming?
By using C language input a date into it and if it is right?
Result of the following program is main() { int i=0; for(i=0;i<20;i++) { switch(i) case 0:i+=5; case 1:i+=2; case 5:i+=5; default i+=4; break;} printf("%d,",i); } } a)0,5,9,13,17 b)5,9,13,17 c)12,17,22 d)16,21 e)syntax error
I use turbo C which allocates 2 bytes for integers and 4 bytes for long. I tried to declare array of size 500000 of long type using the following code... long *arr; arr=(long *)(malloc)(500000 * sizeof(long)); It gives a warning that "Conversion may lose significant digits in function main"... And the resulting array size was very less around 8400 as compared to 500000. Any suggestions will be welcomed....
#include<stdio.h> #include<conio.h> void main() { char ch='\356'; printf("%d",ch); } o/p=-18 why?plz.explain
Disadvantages of C language.
What are the types of macro formats?
What is the use of pragma in embedded c?
consider the following C code main() { int i=3,x; while(i>0) { x=func(i); i--; } int func(int n) { static sum=0; sum=sum+n; return(sum); } the final value of x is