Menu

Strings in bubblecode are enclosed in double quotes. bubblecode provides two concatenation operators and a rich set of built-in string functions.

Concatenation

OperatorEffectExample
&Join directly"Hello" & "World"HelloWorld
&&Join with a space"Hello" && "World"Hello World
example.bubble

String functions

FunctionDescription
length(s)Number of characters
uppercase(s)Convert to UPPERCASE
lowercase(s)Convert to lowercase
reverse(s)Reverse the string
trim(s)Strip leading/trailing spaces
replace(s, old, new)Replace occurrences
example.bubble

Contains check

The contains keyword tests whether one string appears inside another. It returns true or false.

example.bubble

The quote constant

The built-in quote constant holds a double-quote character, useful for building strings that contain quotes.

example.bubble