Flowgorithm Output Statement [ 2024 ]
Flowgorithm Output Statement
In this tutorial, we will learn about the Flowgorithm Output Statement. An Output statement allows you to view the information on the Console Window.
Output Statement
An Output statement evaluates an expression and then displays the result on the Console Window. By default, the output statement is represented with a green color parallelogram.
Add Output Symbol
Click on the flow control line. The flowchart symbols/figures will appear in a pop-up window. Move the mouse over the green parallelogram with the wording “Output.” A blue rectangle will highlight it.
Click on the figure with the left mouse button, and the output figure will be inserted into the flowchart diagram. Initially, the figure will appear gray. The gray color indicates that the output figure is incomplete. We need to provide more information for the symbol to function.
Double-click on the output figure to enter the edit mode. We can provide an expression that needs to appear on the Console window.
For example, display the “Hello, World” text on the Console Window.
Click on the OK button to continue.
We can check the New Line option if required. This option acts like the Carriage Return function for the output and affects the display of the next output messages with or without a carriage return. The Flowgorithm will create an output message on a new line for each Output symbol.
The green color of the output figure will indicate successful creation.
XML Syntax
XML | Flowchart Output Symbol |
<output expression=”” newline=”True”/>
The XML tag for the Output symbol. The symbol is empty and the expression that prints on the console window are not defined yet. |
|
<output expression=”"Hello World!"” newline=”True”/>
The XML tag for the Output symbol with expression defined. The symbol prints Hello World! message onto the console window. |
Exercises
#1
Print two lines of text on the Console window using two Output symbols.
Desired Output:
Hello
World
#2
Correct the error in the flowchart. The programmer aims to print Hello onto the Console window. However, the flowchart throws the following error:
Variable Not Declared
—
Flowgorithm Tutorials
Flowgorithm flowchart tutorials on this website:
https://www.testingdocs.com/flowgorithm-flowchart-tutorial/