Functions and Function Calls

Functional modularization allows us to divide the job of software implementation among programmers: We put groups of functions in different source files, assign a programmer to each file, and let the programmers work in parallel. Obviously, a programmer can work on several functions or several files, but several programmers cannot work simultaneously on the same function. If the function is so large that several programmers should work on it, it should be broken into several functions.

Other advantages of using functions include:

  • caller's code is expressed in terms of function calls (whose names should reflect the meaning of the operations) that is more readable than lower-level computations

  • size of the source (and ...

Get Core C++ A Software Engineering Approach 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.