the caller is the function that makes a call to another function. the other called function is the callee
the single return value can be used to return an error identifier after writing result values via pointer arguments
there is always only one error status but multiple result values are possible
for example, acted-on arguments first, and output arguments last:
especially when the argument count is variable, it may be preferable to put the output arguments first:
using globals might save declaration overhead, but access of a local is often faster because the compiler can better predict where it will be modified and prepare to cache data
performance example
global
local
0m9.931s
0m9.940s
all stack allocations are made at the beginning of a function call, regardless of where they are declared. having all declarations grouped together at the beginning of functions may make it clearer what is actually happening. having all declarations at the top may make finding declarations easier than searching them scattered throughout the function body.
allocates and returns memory