Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 8

Behavioral Modeling

TAj

Case Statement

The case statement selects one of the branches for execution based on the value of the expression.

Loop Statement

loop statement is used to iterate through a set of sequential statements

There are three types of iteration schemes. The first is the for iteration scheme that has the form

Example

The second is the while iteration scheme that has the form

Example

Exit iteration scheme

Exit Statement

The exit statement is a sequential statement that can be used only inside a loop. It causes execution to jump out of the innermost loop or the loop whose label is specified.

Example

Next Statement

The next statement is also a sequential statement that can be used only inside a loop. The syntax is the same as that for the exit statement except that the keyword next replaces the keyword exit.

Assertion Statement
Assertion statements are useful in modeling constraints of an entity.

You might also like