20
#include<stdio.h> void main() { float x = 1.66, y = 1.75; printf(“%f%f”,ceil(x), floor(y)); }

#include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

Embed Size (px)

Citation preview

Page 1: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

float x = 1.66, y = 1.75;printf(“%f%f”,ceil(x), floor(y));

}

Page 2: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int x = 10, y =20;if(!(!x) && x) printf(“x = %d”,x);else

printf(“y = %d“,y);}

Page 3: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int a = 500, b=100,c;if(!a >= 400) b = 300;c = 200;printf(“b = %d c = %d”,b,c);

}

Page 4: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int a = 10,b;a >= 5 ?b=100 :b=200;printf(“%d”,b);

}

Page 5: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

Which of the following cannot be checked in a switch - case statement?

a.Characterb.Integerc.Float

Page 6: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

Which of the following are unary operators in C?a.!b.sizeofc.~d.&&e.=

Page 7: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

static int a[20];int i = 0;a[i] = i++;printf(“%d%d%d”,a[0],a[1],i);

}

Page 8: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int I = 3;i = i++;printf(“%d”,i);

}

Page 9: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int x = 4,y,z;y = --x; z = x--;printf(“%d%d%d”,x,y,z);

}

Page 10: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int x = 55;printf(“%d%d%d”,x<=55,x=40,x>=10);

}

Page 11: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>#define SQR(x) (x * x)void main(){

int a, b =3;a = SQR(b+2);printf(“%d”,a);

}

Page 12: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int arr[1] = {10};printf(“%d”, 0[arr]);

}

Page 13: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

If the array begins at address 1200 in memory, what will be the output of the program?

#include<stdio.h>void main(){

int a[] = {1,2,3,4,5};printf(“%u%u%u”,arr,&arr[0],&arr);

}

Page 14: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

float a[] = {1.2,2.4,3.5,4.5};printf(“%d”, sizeof(a) / sizeof(a[0]));

}

Page 15: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

printf(“%c”, “abcdefgh”[4]);}

Page 16: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

printf(5 + “Fascimile\n”)}

o/p : mile

Page 17: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

int I;printf(“%d”, scanf(“%d”,&i));

}

Page 18: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

char p[] = “%d\n”;p[1] = ‘c’;printf(p,65);

}

Page 19: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

char str[10] = “Angel”;str[6] = ‘d’;printf(“%s”,str);

}o/p : Angel

Page 20: #include void main() { float x = 1.66, y = 1.75; printf(%f%f,ceil(x), floor(y)); }

#include<stdio.h>void main(){

char str[] = “Sales\0man\0”;printf(“%s”,str);

}o/p : Sales