Home Online Manual
Top
Back: string
Forward: string expressions
FastBack: ring
FastForward: vector
Up: string
Top: Singular Manual
Contents: Table of Contents
Index: Index
About: About this document

4.20.1 string declarations

Syntax:
string name = string_expression ;
string name = list_of_string_expressions ;

Purpose:
defines a string variable.

Default:
"" (the empty string)

Example:
 
  string s1="Now I know";
  string s2="how to encode a \" in a string...";
  string s=s1+" "+s2; // concatenation of 3 strings
  s;
==> Now I know how to encode a " in a string...
  s1,s2;   // 2 strings, separated by a blank in the output:
==> Now I know how to encode a " in a string...