Strings are sequences of characters, such as letters, numbers, and symbols, that are treated as a single data value.
Strings in the Flowgorithm are enclosed in double quotes (“). For example, “Hello, World” is a string.
Examples
- “Lionel Messi”
- “1234”
- “ChatGPT-4o”
- “Admin_$”
Create String variable
In this example, let’s create a String variable. The String variable is the name of the company that holds the company name.Â
In the above example, we have created a String variable using the Declare symbol.Â
company = “Google, Inc”
Next, we assigned a string to the variable using the Assign symbol. We use the Assign flowchart symbol to store the data in the variable.
& Operator
To combine two or more strings, we use the & operator, which is the Flowgorithm string concatenation operator. Concatenation is the process of combining two or more strings into one string.Â
Example
“Testing” & “Docs.com” the result would be:
TestingDocs.com