Which of the following is a type of subprogram? I. Functions II. Subroutines
2021
Which of the following is a type of subprogram? I. Functions II. Subroutines
- A.
Only I
- B.
Only II
- C.
Both I and II
- D.
Neither I nor II
Attempted by 486 students.
Show answer & explanation
Correct answer: C
In computer science, both functions and subroutines are standard classifications of subprograms used to modularize code effectively. Functions typically return values, while subroutines perform specific actions without necessarily returning a value, yet both fall under the broader category of subprograms in programming theory.