String( obj )
String( obj, length )
String returns a representation of the obj, which may be an object of
arbitrary type, as a string. This string should approximate as closely
as possible the character sequence you see if you print obj.
If length is given it must be an integer. The absolute value gives the minimal length of the result. If the string representation of obj takes less than that many characters it is filled with blanks. If length is positive it is filled on the left, if length is negative it is filled on the right.
gap> String( 123 ); "123" gap> String( [1,2,3] ); "[ 1, 2, 3 ]" gap> String( 123, 10 ); " 123" gap> String( 123, -10 ); "123 " gap> String( 123, 2 ); "123"
Up Top Next