main()
{
int i;
printf("%d",scanf("%d",&i)); // value 10 is given as
input here
}
Answers were Sorted based on User's Feedback
Answer / susie
Answer :
1
Explanation:
Scanf returns number of items successfully read and not 1/0.
Here 10 is given as input which should have been scanned
successfully. So number of items read is 1.
Is This Answer Correct ? | 24 Yes | 1 No |
main() { char *p = “ayqm”; printf(“%c”,++*(p++)); }
29 Answers IBM, TCS, UGC NET, Wipro,
main() { printf("%x",-1<<4); }
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,
how can i search an element in an array
2 Answers CTS, Microsoft, ViPrak,
main() { unsigned int i=65000; while(i++!=0); printf("%d",i); }
How we will connect multiple client ? (without using fork,thread)
int i; main(){ int t; for ( t=4;scanf("%d",&i)-t;printf("%d\n",i)) printf("%d--",t--); } // If the inputs are 0,1,2,3 find the o/p
main() { char s[ ]="man"; int i; for(i=0;s[ i ];i++) printf("\n%c%c%c%c",s[ i ],*(s+i),*(i+s),i[s]); }
#define a 10 void foo() { #undef a #define a 50 } int main() { printf("%d..",a); foo(); printf("%d..",a); return 0; } explain the answer
main() { int i, j, *p; i = 25; j = 100; p = &i; // Address of i is assigned to pointer p printf("%f", i/(*p) ); // i is divided by pointer p } a. Runtime error. b. 1.00000 c. Compile error d. 0.00000
source code for delete data in array for c
main() { int c = 5; printf("%d", main||c); } a. 1 b. 5 c. 0 d. none of the above