main()
{
struct student
{
char name[30];
struct date dob;
}stud;
struct date
{
int day,month,year;
};
scanf("%s%d%d%d", stud.rollno, &student.dob.day,
&student.dob.month, &student.dob.year);
}
Answer / susie
Answer :
Compiler Error: Undefined structure date
Explanation:
Inside the struct definition of ‘student’ the member of type
struct date is given. The compiler doesn’t have the
definition of date structure (forward reference is not
allowed in C in this case) so it issues an error.
| Is This Answer Correct ? | 1 Yes | 0 No |
main() { int i=-1; -i; printf("i = %d, -i = %d \n",i,-i); }
main() { extern int i; i=20; printf("%d",sizeof(i)); }
void main() { if(~0 == (unsigned int)-1) printf(“You can answer this if you know how values are represented in memory”); }
program to find the roots of a quadratic equation
14 Answers College School Exams Tests, Engineering, HP, IIIT, Infosys, Rajiv Gandhi University of Knowledge Technologies RGUKT, SSC,
Write a Program in 'C' To Insert a Unique Number Only. (Hint: Just Like a Primary Key Numbers In Database.) Please Some One Suggest Me a Better Solution for This question ??
String copy logic in one line.
How will you print % character? a. printf(“\%”) b. printf(“\\%”) c. printf(“%%”) d. printf(“\%%”)
void main() { static int i=i++, j=j++, k=k++; printf(“i = %d j = %d k = %d”, i, j, k); }
main() { printf("%d", out); } int out=100;
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() { { unsigned int bit=256; printf("%d", bit); } { unsigned int bit=512; printf("%d", bit); } } a. 256, 256 b. 512, 512 c. 256, 512 d. Compile error
main() { int i=10; i=!i>14; Printf ("i=%d",i); }