Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2025 Foundation Course
NEET 2025 Foundation Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
714 views
in Information Technology by (95.2k points)
closed by
When a subroutine is called, the address of the instruction following the CALL instructions stored in /on the __________.  
1. Stack
2. Accumulator
3. Stack pointer 
4. Program counter 

1 Answer

0 votes
by (95.4k points)
selected by
 
Best answer
Correct Answer - Option 1 : Stack

Concept:

A subroutine is a subprogram or code that can be executed anywhere in a program. It performs specific tasks such as save the file, display of time, etc.

Explanation:

A subroutine can be called many times during the execution of the program. Calling a subroutine involves :

  • passing arguments
  • save return address
  • transfer control to the callee
  • transfer control back to the caller
  • return results

When a subroutine is called, the address of the instruction following the CALL instructions stored in /on the stack.  The return address associated with a subroutine is stored in either a processor register or in memory called stack. The program counter then fetches the address of the next instruction from the stack.

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...