Bomboclaat!
Flogo has crashed. This is not a problem with your program but a bug in Flogo.
Your program can be recovered.
Unfortunately, your program was lost in the crash.
Try restarting the app, if the problem persists, try another browser.
Flogo has just recovered from a crash. What do you want to do?
Information about your program. This will be saved into the program when you save it.
Choose a theme for the application. This setting will be saved for the current user, but not in your program.
Save the flow chart as an image, so you can put it in your documents or web pages. Note that exported programs are just images and you won't be able to open them in Flogo.
Don't touch these unless you know what you're doing.
Variables can be used to store data that your program needs to work.
Each variable has:
n is not the same as the variable N.
Can be used to store integer numbers, positive or negative.
If a real number is stored into an integer, the decimal digits are lost.
Valid values for an integer are -9007199254740991 to 9007199254740991.
Can be used to store real numbers, positive or negative.
Real numbers don't have a valid range, but they lose accuracy as they become larger.
It is generally a bad idea to store an integer number in a real variable.
Can be used to store text. The maximum allowed length is `1048576` characters (about 1 million).
Can store a value that's either true or false.
Reads a value from the user and stores it in a variable.
Evaluates an expression and shows the result to the user.
+ symbol. Example: "The total is "+total+"€"Evaluates an expression and stores the result in a variable.
Be careful! Some automatic type conversions can happen if variables are not of the same type. For instance, if the expression gives a real value but your variable is an integer, it will lose the decimal digits; if the expression gives an integer number and your variable is a string, it will be converted to text. Your program only crashes if the types are completely incompatible, for instance if your expression gives a string but you're trying to store it in a real variable.
Evaluates an expression and executes the True or False branch depending on the result.
The expression can contain numbers, variables, mathematical operators, etc. but it can also contain comparison and logical operators. For instance, the expression a>=0&&a<=10 tells you if the variable a is between 0 and 10.
It's important to remember that the expression must give a true/false value, any other type will crash your program.
Repeats the instructions inside it until the condition at the end becomes false.
The condition is checked at the end of each loop, so the contents of the loop will always be executed at least once; this makes it useful for things like input validation.
Like in the If instruction, the condition must give a true/false value.
Repeats the instructions inside it until the condition at the top becomes false.
The condition is checked at the beginning of each loop, so it's possible for the loop to not be executed at all if the condition is immediately false.
Like in the If instruction, the condition must give a true/false value.
A for loop repeats the instructions inside it like a While loop, but it also handles a variable (usually a counter) automatically, incrementing or decrementing it at the end of each loop.
Note: the from-to range is inclusive!
Comments have no effect on the program, they are useful to store notes or to document how things work.
Automatically pauses execution of the program. Useful for debugging.
Expressions can be used to write mathematical expressions, conditions and conditions.
Expressions can contain a mix of variables, values, operators and functions.
Variable names and numeric values can be written directly (for instance, a+1), strings must use quotes or double quotes (for instance, 'The price is: '+price), functions use parenthesis and commas to delimit their parameters (for instance, toFixed(price,2)).
Expressions are evaluated in this order:
The following tables list all the operators included in Flogo in order of precedence. Round parenthesis can be used to alter the order of evaluation of the expression (for instance, n/(a+1)); parenthesis can also be nested.
| Operator | Description |
|---|---|
| a ^ b | Power |
| a * b | Multiplication |
| a / b | Division (real) |
| a % b | Modulus (remainder of integer division) |
| a + b | Addition (if both operands are numbers) |
| a + b | String concatenation (if at least one of the operands is a string) |
| a - b | Subtraction |
Comparison operators can be used in conditions to compare a value to another. For instance, a==0 is true if the variable a has a value of 0.
| Operator | Description |
|---|---|
| a < b | Lower than |
| a > b | Greater than |
| a <= b | Lower or equal |
| a >= b | Greater or equal |
| a == b | Equals |
| a != b | Different |
Logical operators allow you to "chain together" multiple conditions. For instance, a<0||a>10 is true if the variable a is not between 0 and 10.
| Operator | Description |
|---|---|
| ! expr | Not Inverts the value of the expression |
| a && b | And All expressions must be true for the entire condition to be true |
| a || b | Or At least one expression must be true for the entire condition to be true |
Flogo has a lot of buit-in functions that make writing expressions easier. For instance, round(a) will give you the value of the variable a rounded mathematically.
| Function | Description |
|---|---|
| abs(n) | Absolute value |
| sqrt(n) | Square root |
| sin(n) | Sine (n is an angle in radians) |
| cos(n) | Cosine (n is an angle in radians) |
| tan(n) | Tangent (n is an angle in radians) |
| asin(n) | Arcsine |
| acos(n) | Arcosine |
| atan(n) | Arctangent |
| ln(n) | Natural logarithm (base E) |
| log(base,val) | Logarithm |
| ceil(n) | Round up to nearest integer |
| floor(n) | Round down to nearest integer |
| round(n) | Mathematical rounding |
| random() | Random real number between 0 and 1 |
| Function | Description |
|---|---|
| toFixed(n,d) | Converts a number into a string with d decimal digits |
| len(s) | Length of a string |
| charAt(s,i) | Returns the character in position i in the string s. The first character in a string has position 0 |
| charToCode(c) | Converts a character into the corresponding ASCII code (integer) |
| codeToChar(n) | Converts an ASCII code into the corresponding character |
| strToReal(s) | Converts a string into a real number |
| strToInt(s) | Converts a string into an integer number |
| Constant | Value |
|---|---|
| PI | 3.141592653589793 |
| E | 2.718281828459045 |
| CURRENT_DAY | Current day of month |
| CURRENT_MONTH | Current month (1=January, 12=December) |
| CURRENT_YEAR | Current year |
| CURRENT_HOURS | Current hours (24h format) |
| CURRENT_MINUTES | Current minutes |
| CURRENT_SECONDS | Current seconds |
The basic concept behind Turtle Graphics is that you're controlling a cursor (called "turtle", but his real name is Augustino). When the program is started, the turtle is at the center of the drawing area and it's pointing up (this is its "home"), and you can use instructions to move it, draw a line while moving, turn it left or right and it can also instantly move back to its home.
A Move/Draw instruction moves the turtle by the specified distance in the direction that it's currently pointing at. It can draw a line behind it while moving.
A Move/Draw instruction changes the angle that the turtle is currently pointing at by a specified amount of degrees.
Instantly moves the turtle back to the starting position (its "home"), pointing upwards. It does not draw a line while moving.