Programming Code (840)
Scripts_Markup Code (257) Declare an array of N pointers to functions returning pointers to functions returning pointers to characters?
1 4127main() { 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); }
1 5445main() { struct date; 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); }
1 7686There were 10 records stored in “somefile.dat” but the following program printed 11 names. What went wrong? void main() { struct student { char name[30], rollno[6]; }stud; FILE *fp = fopen(“somefile.dat”,”r”); while(!feof(fp)) { fread(&stud, sizeof(stud), 1 , fp); puts(stud.name); } }
1 4820Is there any difference between the two declarations, 1. int foo(int *arr[]) and 2. int foo(int *arr[2])
1 5796What is the subtle error in the following code segment?
void fun(int n, int arr[])
{
int *p=0;
int i=0;
while(i++
What is wrong with the following code? int *foo() { int *s = malloc(sizeof(int)100); assert(s != NULL); return s; }
1 4801void main() { int *i = 0x400; // i points to the address 400 *i = 0; // set the value of memory location pointed by i; }
2 5778#define assert(cond) if(!(cond)) \ (fprintf(stderr, "assertion failed: %s, file %s, line %d \n",#cond,\ __FILE__,__LINE__), abort()) void main() { int i = 10; if(i==0) assert(i < 100); else printf("This statement becomes else for if in assert macro"); }
1 8086Is the following code legal? void main() { typedef struct a aType; aType someVariable; struct a { int x; aType *b; }; }
1 5181
can any one give me code to keyed a flat file and used chain in RPGLE to search any item
Write a Program to find the reverse of a given number.
How can call any javascript function without saying onclick, onchange, onblur etc events in php?
program to bring a window to the front
What is the code of Password Recovery or Forget your password? Plz tell in c # language.
how to create an anonymous function
determine which Element received an Event
Code to Block submission of form by pressing Enter Key
Write a function that takes an integer and returns the smallest number that is greater than the given number which is a palendrome. For example, if the input was 111 the next palindromic number would be 121.
How to Get File Extension?
What is XML DOM Document?
How to swap two ASCII numbers?
Write a program that print in screen a tree with its height taken from user by entering number of 4 digits and find the odd numbers then calculate the sum of odd numbers so he get the height of tree?
Can we run Applet in Web browser with security policy files
Can Any one suggest how we connect QTP and Mainframe and do validation from Mainfram screen