Computer Science, asked by Anonymous, 2 months ago

Why is a macro used in place of a function​

Answers

Answered by Anonymous
0

Answer:

Speed versus size The main benefit of using macros is faster execution time. During preprocessing, a macro is expanded inline each time it is used.

Answered by adventureisland
2

While users define macro on functions, the computer saves so much time when calling up the functions.

Uses of macro in place of a function.

  • While users define macro on functions, the computer saves so much time when calling up the functions. As a result, the benefit of a macro over a function is speed.
  • Because control doesn't ever leave the home function, giving control to a new function takes no time.
  • A macro is used to automate a job that you do on a regular basis or repeatedly. It's a collection of instructions and actions that you may save and use anytime you need to complete a task.

Similar questions