logo

CuriousTab

CuriousTab

Discussion


Home Technical Questions Database See What Others Are Saying!
  • Question
  • If you are using C language to implement the heterogeneous linked list, what pointer type will you use?


  • Correct Answer
  • The heterogeneous linked list contains different data types in its nodes and we need a link, pointer to connect them It is not possible to use ordinary pointers for this So we go for void pointer Void pointer is capable of storing pointer to any type as it is a generic pointer type 

  • Tags: Database Administrator

    More questions

    • 1. What are various scheduling queues?
    • Discuss
    • 2. What is the state of the processor, when a process is waiting for some event to occur?
    • Discuss
    • 3. What is Memory-Management Unit (MMU)?
    • Discuss
    • 4. SNOBOL is mainly used for

    • Options
    • A. Text Operation
    • B. String operations
    • C. List operations
    • D. Numerical operations
    • Discuss
    • 5. Convert the expression ((A + B) * C ? (D ? E) ^ (F + G)) to equivalent Prefix Notation
    • Discuss
    • 6. What would be the output of the following program? main() { char a[] = "Visual C++"; char *b = "Visual C++"; printf ("\n%d %d", sizeof (a), sizeof (b)); printf ("\n%d %d", sizeof (*a), sizeof (*b)); }
    • Discuss
    • 7. Point out the error, if any, in the following program. #include "stdarg.h" main() { display ( 4, 12.5, 13.5, 14.5, 44.3); } display(int num, ...) { float c; int j; va_list ptr; va_start (ptr, num); for ( j = 1; j <= num; j++) { c = va_arg ( ptr, float ); printf ("\n%f", c); } }
    • Discuss
    • 8. Two main measures for the efficiency of an algorithm are

    • Options
    • A. Time and Space
    • B. Complexity and Memory
    • C. Data and Space
    • D. Memory and Processor
    • Discuss
    • 9. Would the following program compile? main() { int a = 10, *j; void *k; J = k = &a; J++; k++; printf ("\n%u %u", j, k); }
    • Discuss
    • 10. What would be the output of the following program? main() { char ch ='A'; printf ("%d%d", sizeof (ch), sizeof ('A')); }
    • Discuss


    Comments

    There are no comments.

Enter a new Comment