Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Programming Procedures & Functions: Declaration, Arguments, & Access Specifiers, Quizzes of Software Engineering

Definitions and explanations for declaring procedures and functions in programming, including the format for procedure and function declaration, passing arguments by value and by reference, and the use of access specifiers. It also covers the concept of static local variables.

Typology: Quizzes

2012/2013

Uploaded on 05/02/2013

jmo1012
jmo1012 🇺🇸

12 documents

1 / 3

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
TERM 1
What is the format for declaring a procedure?
DEFINITION 1
[accessSpecifier] sub procedure name (parameter list)
StatementsEnd Sub
TERM 2
What are the 2 ways to pass an argument?
DEFINITION 2
By value and by reference
TERM 3
what is passing an argument by value?
DEFINITION 3
only a copy of the argument is passed to the procedure. It
cannot make changes to the original argument
TERM 4
what is passing an argument by reference?
DEFINITION 4
the procedure has access to the original argument and can
make changes to it.
TERM 5
How do you declare a
function?
DEFINITION 5
[accessSpecifier] Functionprocedure name(parameter list) As
DataType Statements Return statementEnd Function
pf3

Partial preview of the text

Download Programming Procedures & Functions: Declaration, Arguments, & Access Specifiers and more Quizzes Software Engineering in PDF only on Docsity!

TERM 1

What is the format for declaring a procedure?

DEFINITION 1

[accessSpecifier] sub procedure name (parameter list)

StatementsEnd Sub

TERM 2

What are the 2 ways to pass an argument?

DEFINITION 2

By value and by reference

TERM 3

what is passing an argument by value?

DEFINITION 3

only a copy of the argument is passed to the procedure. It

cannot make changes to the original argument

TERM 4

what is passing an argument by reference?

DEFINITION 4

the procedure has access to the original argument and can

make changes to it.

TERM 5

How do you declare a

function?

DEFINITION 5

[accessSpecifier] Functionprocedure name(parameter list) As

DataType Statements Return statementEnd Function

TERM 6

what is a procedure

DEFINITION 6

A collection of statements that performs a task

TERM 7

what is a function?

DEFINITION 7

a collection of statements that performs a task and then

returns a value to the part of the program that executed it.

TERM 8

what is a static local variable, and what is it

used for?

DEFINITION 8

The variable is stored in a local variable. These variables are

not destroyed when a procedure terminates. They will exist

for the lifetime of the application. example: Static variable

name As Datatype

TERM 9

What are the different access specifiers?

DEFINITION 9

prive, public, protected, friend, and protected frined

TERM 10

What statement does a function must have

in?

DEFINITION 10

Return statement