Function Subprograms

CS-185 Fall '97 Learning Objectives


Function Subprograms

Be able to name the two types of subprograms in Fortran.

Be able to explain the difference between intrinsic and programmer-defined functions.

Know how to declare function subprograms.

Be able to explain why Dr. Tritt prefers to place function type identifiers before function names in declarations.

Be able to use intent specifers and explain why they are useful.

Be able to explain what happens when a return statement is executed from within a function.

Be able to explain why only module subprograms should be used in modern Fortran programs.

Be able to explain the difference between pass by value and pass by reference mechanisms and know which one Fortran normally uses.

Be able to clearly state the difference between actual and formal subprogram arguments.

Be able to explain why assumed length specifers can be used in subprograms but not main programs.

Be able to explain what is meant by the scope of an identifier.

Be able to explain the difference between local and global identifiers.

Be able to explain why it is dangerous to use internal subprograms and global variables.

Be able to explain how the values of local variables can be saved between calls.

Be able to explain what a program stub is.

Be able to explain what modules are.

Know how to declare and define a module and the subprogram it contains.

Be able to incorporate subprograms into a program using modules.

Be able to name the only type of function subprogram available in old style Fortran 77.

Be able to explain the difference between implicit and explicit interfaces and describe the problem with implicit interfaces.


Send comments and suggestions about these objectives to: Charles S. Tritt, Ph.D.
This page last updated 10/12/97