The Bohm-Jacobini theorem states that any flowgraph can be replaced by one with the same functionality that only uses the sequence, if-then-else, while and assignment statements (i.e., prime program components). Show that you don't need the if-then-else. That is, sequence, while and assignment are sufficient. _____

Fill in the blank(s) with the appropriate word(s).


if p then S else T; can be replaced by:
notdoneflag := true;
while p and notdoneflag do
{S; notdoneflag:= false}
while not(p) and notdoneflag do
{T; notdoneflag:= false}

Computer Science & Information Technology

You might also like to view...

When you buy software, you can only use it as specified in the EULA

Indicate whether the statement is true or false

Computer Science & Information Technology

An implementation of the functional interface ______________ takes two T arguments, per- forms an operation on them (such as a calculation) and returns a value of type T.

What will be an ideal response?

Computer Science & Information Technology

JavaScript is embedded in an HTML file and interpreted by a Web browser, such as Mozilla Firefox, Internet Explorer, Google Chrome, or Safari.

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

An if statement is an example of a selection control structure.?

Answer the following statement true (T) or false (F)

Computer Science & Information Technology