SWI-Prolog supports the data type string . Strings are a time and space efficient mechanism to handle text in Prolog. 12 bytes for each character stored. Within strings each character only requires 1 byte storage. Strings live on the global stack and their storage is thus reclaimed on backtracking.
Garbage collection can easily deal with strings.
The set of predicates associated with strings is incomplete and tentative. Names and definitions might change in the future to confirm to the emerging standard. Logical conversion between a string and an atom. At least one of the two arguments must be instantiated. Atom can also be an integer or floating point number.