#include<stdio.h>
main()
{
struct xx
{
int x=3;
char name[]="hello";
};
struct xx *s=malloc(sizeof(struct xx));
printf("%d",s->x);
printf("%s",s->name);
}
Answer / susie
Answer :
Compiler Error
Explanation:
Initialization should not be done for structure members
inside the structure declaration
| Is This Answer Correct ? | 4 Yes | 1 No |
main() { while (strcmp(“some”,”some\0”)) printf(“Strings are not equal\n”); }
writte a c-programm to display smill paces
void main() { static int i; while(i<=10) (i>2)?i++:i--; printf(“%d”, i); }
int DIM(int array[]) { return sizeof(array)/sizeof(int ); } main() { int arr[10]; printf(“The dimension of the array is %d”, DIM(arr)); }
main() { printf("%x",-1<<4); }
What is the output for the program given below typedef enum errorType{warning, error, exception,}error; main() { error g1; g1=1; printf("%d",g1); }
int main() { int x=10; printf("x=%d, count of earlier print=%d", x,printf("x=%d, y=%d",x,--x)); getch(); } ================================================== returns error>> ld returned 1 exit status =================================================== Does it have something to do with printf() inside another printf().
Write a C function to search a number in the given list of numbers. donot use printf and scanf
Write a program that reads a dynamic array of 40 integers and displays only even integers
union u { struct st { int i : 4; int j : 4; int k : 4; int l; }st; int i; }u; main() { u.i = 100; printf("%d, %d, %d",u.i, u.st.i, u.st.l); } a. 4, 4, 0 b. 0, 0, 0 c. 100, 4, 0 d. 40, 4, 0
Write a program to receive an integer and find it's octal equivalent. How can i do with using while loop.
To reverse an entire text file into another text file.... get d file names in cmd line