Developing Applications and Automating Workflows Using Cisco Platforms (DEVASC) — Question 10
Which statement describes the benefit of using functions in programming?
Answer options
- A. Functions ensure that a developer understands the inner logic contained before using them as part of a script or application.
- B. Functions create the implementation of secret and encrypted algorithms.
- C. Functions allow problems to be split into simpler, smaller groups, and reduce code repetition, which makes the code easier to read.
- D. Functions store mutable values within a script or application.
Correct answer: C
Explanation
The correct answer is C because functions help break down complex problems into simpler components, which reduces redundancy in the code and enhances its readability. Option A is incorrect as understanding inner logic is not a benefit of using functions; option B is misleading since functions do not inherently create secret algorithms; and option D is wrong because functions do not store mutable values but rather define processes or behaviors.