main()
{
float i=1.5;
switch(i)
{
case 1: printf("1");
case 2: printf("2");
default : printf("0");
}
}
Answers were Sorted based on User's Feedback
Answer / susie
Answer :
Compiler Error: switch expression not integral
Explanation:
Switch statements can be applied only to integral types.
Is This Answer Correct ? | 16 Yes | 2 No |
Answer / mina
Compiler Error.
switch operates only with char and int.
Is This Answer Correct ? | 3 Yes | 0 No |
How to use power function under linux environment.eg : for(i=1;i<=n;i++){ pow(-1,i-1)} since it alerts undefined reference to 'pow'.
Is the following code legal? typedef struct a aType; struct a { int x; aType *b; };
void main() { char ch; for(ch=0;ch<=127;ch++) printf(ā%c %d \nā, ch, ch); }
main() { extern int i; { int i=20; { const volatile unsigned i=30; printf("%d",i); } printf("%d",i); } printf("%d",i); } int i;
main() { int x=5; clrscr(); for(;x<= 0;x--) { printf("x=%d ", x--); } } a. 5, 3, 1 b. 5, 2, 1, c. 5, 3, 1, -1, 3 d. ā3, -1, 1, 3, 5
write a c program to input initial & final time in the format hh:mm and find the time intervel between them? Ex inputs are initial 06:30 final 00:05 and 23:22 final 22.30
main() { int x=5; clrscr(); for(;x==0;x--) { printf("x=%d\nā", x--); } } a. 4, 3, 2, 1, 0 b. 1, 2, 3, 4, 5 c. 0, 1, 2, 3, 4 d. none of the above
can you use proc sql to manpulate a data set or would u prefer to use proc report ? if so why ? make up an example and explain in detail
How we will connect multiple client ? (without using fork,thread)
# include <stdio.h> int one_d[]={1,2,3}; main() { int *ptr; ptr=one_d; ptr+=3; printf("%d",*ptr); }
main() { int i=5; printf("%d%d%d%d%d%d",i++,i--,++i,--i,i); }
How to palindrom string in c language?