main()
{
unsigned int i=65000;
while(i++!=0);
printf("%d",i);
}
Answer / susie
Answer :
1
Explanation:
Note the semicolon after the while statement. When the value
of i becomes 0 it comes out of while loop. Due to
post-increment on i the value of i while printing is 1.
| Is This Answer Correct ? | 17 Yes | 5 No |
Write a program to check whether the number is prime and also check if it there i n fibonacci series, then return true otherwise return false
void main() { static int i; while(i<=10) (i>2)?i++:i--; printf(ā%dā, i); }
1. const char *a; 2. char* const a; 3. char const *a; -Differentiate the above declarations.
#define prod(a,b) a*b main() { int x=3,y=4; printf("%d",prod(x+2,y-1)); }
Is there any difference between the two declarations, 1. int foo(int *arr[]) and 2. int foo(int *arr[2])
‎#define good bad main() { int good=1; int bad=0; printf ("good is:%d",good); }
How do I write a program to print proper subset of given string . Eg :input: abc output:{},{a},{b},{c},{a,b},{a,c},{b,c}, {a,b,c}.I desperately need this program please mail me to saravana6m@gmail.com
what will be the output of this program? void main() { int a[]={5,10,15}; int i=0,num; num=a[++i] + ++i +(++i); printf("%d",num); }
int i,j; for(i=0;i<=10;i++) { j+=5; assert(i<5); }
Write a program using one dimensional array to assign values and then display it on the screen. Use the formula a[i]=i*10 to assign value to an element.
1 Answers Samar State University,
In the following pgm add a stmt in the function fun such that the address of 'a' gets stored in 'j'. main(){ int * j; void fun(int **); fun(&j); } void fun(int **k) { int a =0; /* add a stmt here*/ }
main() { char *p; p="Hello"; printf("%c\n",*&*p); }