Review Questions

1:What is the difference between an actual argument and a formal parameter?
2:Write ANSI C function headings for the following functions described. Note we are asking just for the headings, not the body.
  1. donut() takes an int argument and prints that number of 0s.

  2. gear() takes two int arguments and returns type int.

  3. stuff_it() takes a double and the address of a double variable and stores the first value in the given location.

3:Write ANSI C function headings for the following functions described. Note that you need write only the headings, not the body.
  1. n_to_char() takes an int argument and returns a char.

  2. digits() takes a double argument and an int argument and returns an int.

  3. random() takes no argument and returns an int.

4:Devise ...

Get C Primer Plus, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.