Question

Where are module variables, parameters, and temporary variables introduced and initialized in a program?

Where are module variables, parameters, and temporary variables introduced and initialized in a program?

0 0
Add a comment Improve this question Transcribed image text
Answer #1

TEMPORARY VARIABLES :

INTRODUCED : inside a block, they have very short lifetime and hold data that can be discarded or is later stored in a permanent variable

INITIALIZED : temporary variables can be initialized anywhere inside the block where they are declared.

PARAMETERS:

INTRODUCED : parameters are declared inside the parenthesis of the function definition

INITIALIZED : parameters can be initialized where they are declared or can be declared in the parenthesis of the function call

MODULE VARIABLE :

INTRODUCED : A module-level variable is declared for a particular module. It is available to all procedures within that module but not to the rest of the application. Module-level variables remain in existence for the lifetime of the application and preserve their values.

INITIALIZED : module variable gets initialized where they are declared inside the module. it is initialized to 0 by default.

Add a comment
Know the answer?
Add Answer to:
Where are module variables, parameters, and temporary variables introduced and initialized in a program?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT