TestingDocs.com
Software Testing website
  • Automation
    • Selenium
    • JBehave Framework
  • Tutorials
    • MySQL Tutorials
    • Testlink
    • Maven
    • Git
  • IDEs
    • IntelliJ IDEA
    • Eclipse
  • Flowcharts
    • Flowgorithm
    • Raptor
  • About

Flowgorithm

Flowgorithm Declare Statement

Overview

In his tutorial, we will learn about the Flowgorithm Declare statement. Declare statement is used to create variables in the flowchart. Programmers should explicitly declare the variable before using it in the Flowgorithm flowcharts.

Declare Statement

The Declare symbol is a rectangle shape with a horizontal and vertical line inside the rectangle as shown below:

Flowgorithm Declare Statement

The Declare statement is used to create a variable and arrays in the flowchart. We can use the variable to store and retrieve data in the flowchart. When the symbol is not used it appears in gray color by default.

Example

Let’s create a variable called height using the Declare symbol. The data type for the variable is Real.

 

Create a variable Flowgorithm

  • Double click on the symbol to create a variable.
  • Type the variable name in the textbox.
  • Choose the Type: Real
  • Click on the OK button.

The Declare symbol turns into pale yellow color. The symbol will now display the variable data type and the variable name.

 

Variable height Declare Symbol Flowgorithm

 

That’s it. We have successfully created a variable in the flowchart. Now, we can store a value using the Assign flowchart symbol.

Multiple Variables

We can declare multiple variables of the same data type using a single Declare statement. We can declare multiple variables by separating the variable names with commas.

For example, we have declared the length and height of type Real using a single Declare symbol.

Multiple variables Declare

XML Syntax

The following are examples of XML tags for the Declare symbol in the .fprg flowchart file.

XMLFlowchart Declare Symbol
<declare name=”” type=”Integer” array=”False” size=””/>

The XML tag for the Declare flowchart symbol. The symbol and the tag when the variable is not declared.

flowgorithm_declare_xml_empty
<declare name=”num” type=”Integer” array=”False” size=””/>

The XML tag for the Declare flowchart symbol. The symbol and the tag when the variable is declared. The variable name is the num of the Integer data type.

flowgorithm_xml_declare_symbol
<declare name=”arr” type=”Integer” array=”True” size=”10″/>

An array variable arr declaration of the Integer data type. The size of the array is ten.

flowgorithm_array_xml_declare

—

Flowgorithm Tutorials

Flowgorithm flowchart tutorials on this website:

https://www.testingdocs.com/flowgorithm-flowchart-tutorial/

Flowgorithm Website

For more information on the Flowgorithm tool, please visit the official website at:

http://flowgorithm.org/

Related Posts

Print Triangle Pattern Flowchart

Flowgorithm /

Print Triangle Pattern Flowchart

Flowgorithm Breakpoint Symbol

Flowgorithm /

Flowgorithm Conditional Breakpoint Statement

File Read Declare Variables

Flowgorithm /

Flowgorithm Read Numbers from File Example

File Search Input File Flowgorithm

Flowgorithm /

Search Text File Flowchart Example

Flowgorithm Turtle Graphics Symbols

Flowgorithm /

Flowgorithm Turtle Graphics Symbols

‹ Flowgorithm Operators› Flowgorithm Assign Statement

Recent Posts

  • Install RAPTOR Avalonia on CentOS
  • Download RAPTOR Avalonia Edition on Windows
  • npm doctor command
  • Print Triangle Pattern Flowchart
  • RAPTOR Editions
  • Flowgorithm Conditional Breakpoint Statement
  • Flowgorithm Read Numbers from File Example
  • Search Text File Flowchart Example
  • Flowgorithm Turtle Graphics Symbols
  • Draw Circle using Flowgorithm Turtle

Back to Top

Links

  • Contact
  • Privacy Policy
  • Cookie Policy

www.TestingDocs.com

Go to mobile version