LeftStr function
Return a number of characters starting at the left of a string.
Declaration
function LeftStr(const S: string; Count: Integer): stringDescription
LeftStr returns the
Count leftmost characters of
S.
It is equivalent to a call to
Copy(S,1,Count).Errors
None.
See also
Example: ex76
Program Example76;
{ This program demonstrates the LeftStr function }
Uses sysutils;
Begin
Writeln (LeftStr('abcdefghijklmnopqrstuvwxyz',20));
Writeln (LeftStr('abcdefghijklmnopqrstuvwxyz',15));
Writeln (LeftStr('abcdefghijklmnopqrstuvwxyz',1));
Writeln (LeftStr('abcdefghijklmnopqrstuvwxyz',200));
End.An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
