download Mastguru Android App

Question Detail

Difference between structure and union is

  • We can define functions within structures but not within a union
  • We can define functions within union but not within a structure
  • The way memory is allocated
  • There is no difference
Similar Questions :

1. printf() belongs to which library of c

  • stdlib.h
  • stdio.h
  • stdout.h
  • stdoutput.h

2. What is true about fputs function

  • write to a file
  • takes two parameters
  • requires a file pointer
  • all of above

3. Difference between calloc() and malloc()

  • calloc() takes a single argument while malloc() needs two arguments
  • malloc() takes a single argument while calloc() needs two arguments
  • malloc() initializes the allocated memory to ZERO
  • calloc() initializes the allocated memory to NULL

4. Can getch() be used to echo the input

  • Yes
  • No

5. What is correct order of precedence in C

  • Addition, Division, Modulus
  • Addition, Modulus, Division
  • Multiplication, Substration, Modulus
  • Modulus, Multiplication, Substration
Read more from - C Programming Questions Answers - Chapter 1
Post a comment